cmocka: Fix length calculation.
cmocka: Fix length calculation.

CID: #1268624

Signed-off-by: Andreas Schneider <asn@cryptomilk.org>

SQ

wingyplus/cmocka,wingyplus/cmocka,JonathonReinhart/cmocka,clibs/cmocka,VladimirTyrin/cmocka,tyc/cmocka,tyc/cmocka,JonathonReinhart/cmocka,clibs/cmocka,dsch/cmocka,dsch/cmocka,VladimirTyrin/cmocka,jamesmunns/CMocka,tyc/cmocka,jamesmunns/CMocka