Skip to content

Commit f98f5d4

Browse files
committed
BugFix - data length
Even tho this is a "LONG" type, it's actually only 4 bytes. Typecasting it to a long* caused a dereference beyond the end of the allocated region. issues#28
1 parent 9d32c6c commit f98f5d4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: lib/ytnef.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -1390,7 +1390,7 @@ void MAPIPrint(MAPIProps *p) {
13901390
printf("] (%llu)\n", ddword_tmp);
13911391
break;
13921392
case PT_LONG:
1393-
printf(" Value: %li\n", *((long*)mapidata->data));
1393+
printf(" Value: %i\n", *((int*)mapidata->data));
13941394
break;
13951395
case PT_I2:
13961396
printf(" Value: %hi\n", *((short int*)mapidata->data));

0 commit comments

Comments
 (0)