1 Dike out a section of code that has no usefulness on Unix-like systems,
2 and will crash if fed a comment string exceeding 64K. Per report from
3 Lubomir Kundrak, RH bug #226965
6 diff -Naur jpeg-6b.orig/wrjpgcom.c jpeg-6b/wrjpgcom.c
7 --- jpeg-6b.orig/wrjpgcom.c 1997-10-23 00:47:03.000000000 -0400
8 +++ jpeg-6b/wrjpgcom.c 2007-06-25 22:26:42.000000000 -0400
10 } else if (keymatch(arg, "comment", 1)) {
11 if (++argn >= argc) usage();
12 comment_arg = argv[argn];
14 +#error "There is a buffer overflow in the code below"
15 /* If the comment text starts with '"', then we are probably running
16 * under MS-DOG and must parse out the quoted string ourselves. Sigh.
19 strcat(comment_arg, argv[argn]);
23 comment_length = (unsigned int) strlen(comment_arg);