projects
/
silc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Cleanup: limit length of strings scanned by scanf.
[silc.git]
/
apps
/
silcmap
/
silcmap_bitmap.c
diff --git
a/apps/silcmap/silcmap_bitmap.c
b/apps/silcmap/silcmap_bitmap.c
index 6440f88ddcc8e6208d3263f2ad5ce07428cca756..b171f47bed1f77a178a0988410980137c35942b9 100644
(file)
--- a/
apps/silcmap/silcmap_bitmap.c
+++ b/
apps/silcmap/silcmap_bitmap.c
@@
-52,7
+52,7
@@
bool silc_map_load_ppm(SilcMap map, const char *filename)
}
/* Read width and height */
- ret = sscanf(header, "%s %ld %ld %ld\n", type,
+ ret = sscanf(header, "%
2
s %ld %ld %ld\n", type,
(unsigned long *)&map->width,
(unsigned long *)&map->height,
(unsigned long *)&map->maxcolor);