forked from osmocom/wireshark
Androiddump: Fix Memory - corruptions (OVERRUN) (CID 1293632)
Change-Id: Ifd0d5026d207f763e1726963049acfb5a77f4b39 Reviewed-on: https://code.wireshark.org/review/8075 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
This commit is contained in:
parent
40ce324f4d
commit
3c110d7bb2
|
@ -540,7 +540,7 @@ static int add_android_interfaces(struct interface_t **interface_list,
|
|||
pos = strchr(pos, '\t');
|
||||
result = (int) (pos - prev_pos);
|
||||
pos = strchr(pos, '\n') + 1;
|
||||
if (result > (int) sizeof(serial_number)) {
|
||||
if (result >= (int) sizeof(serial_number)) {
|
||||
fprintf(stderr, "WARNING: Serial number too long, ignore device\n");
|
||||
continue;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue