Skip to content

Commit

Permalink
avoid potential sprintf overflow (GCC7)
Browse files Browse the repository at this point in the history
  • Loading branch information
msmeissn committed Jun 1, 2017
1 parent 100373e commit 6aaa8da
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions camlibs/ptp2/config.c
Original file line number Diff line number Diff line change
Expand Up @@ -1605,7 +1605,7 @@ _put_ImageSize(CONFIG_PUT_ARGS) {
static int
_get_ExpCompensation(CONFIG_GET_ARGS) {
int j;
char buf[10];
char buf[13];

if (!(dpd->FormFlag & PTP_DPFF_Enumeration))
return GP_ERROR;
Expand Down Expand Up @@ -7710,7 +7710,7 @@ _get_config (Camera *camera, const char *confname, CameraWidget **outwidget, Cam

for (i=0;i<params->deviceinfo.DevicePropertiesSupported_len;i++) {
uint16_t propid = params->deviceinfo.DevicePropertiesSupported[i];
char buf[20], *label;
char buf[21], *label;
PTPDevicePropDesc dpd;
CameraWidgetType type;

Expand Down

0 comments on commit 6aaa8da

Please sign in to comment.