Skip to content

Commit

Permalink
ptp_unpack_CANON_changes: fix bug in bounds checking code
Browse files Browse the repository at this point in the history
  • Loading branch information
axxel authored and msmeissn committed Sep 23, 2024
1 parent 4d6f9b6 commit 6177718
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion camlibs/ptp2/ptp-pack.c
Original file line number Diff line number Diff line change
@@ -2568,7 +2568,7 @@ ptp_unpack_CANON_changes (PTPParams *params, const unsigned char* data, unsigned
dpd->DataType = PTP_DTC_STR;
free (dpd->FactoryDefaultValue.str);
free (dpd->CurrentValue.str);
dpd->FactoryDefaultValue.str = ptp_unpack_EOS_FocusInfoEx( params, &xdata, size );
dpd->FactoryDefaultValue.str = ptp_unpack_EOS_FocusInfoEx( params, &xdata, xsize );
dpd->CurrentValue.str = strdup( (char*)dpd->FactoryDefaultValue.str );
ptp_debug (params," value of %x is %s", proptype, dpd->CurrentValue.str);
break;

0 comments on commit 6177718

Please sign in to comment.