Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 384311
Collapse All | Expand All

(-)file_not_specified_in_diff (-6 / +7 lines)
Line  Link Here
0
-- config.c
0
++ config.c
Lines 351-370 Link Here
351
		 * marker if it occurs at the beginning of the line, or after
351
		 * marker if it occurs at the beginning of the line, or after
352
		 * whitespace
352
		 * whitespace
353
		 */
353
		 */
354
		hashmarker = strchrnul(line, '#');
354
		hashmarker = strchr(line, '#');
355
		if (line == hashmarker)
355
		if (line == hashmarker)
356
			line[0] = '\0';
356
			line[0] = '\0';
357
		else {
357
		else {
358
			while (hashmarker[0] != '\0') {
358
			while (hashmarker != NULL) {
359
				--hashmarker;
359
				--hashmarker;
360
				if (isblank(hashmarker[0]))
360
				if (isblank(hashmarker[0])) {
361
					hashmarker[0] = '\0';
361
					hashmarker[0] = '\0';
362
				else {
362
					break;
363
				} else {
363
					/*
364
					/*
364
					 * false positive; '#' occured
365
					 * false positive; '#' occured
365
					 * within a string
366
					 * within a string
366
					 */
367
					 */
367
					hashmarker = strchrnul(hashmarker+2, '#');
368
					hashmarker = strchr(hashmarker+2, '#');
368
				}
369
				}
369
			}
370
			}
370
		}
371
		}

Return to bug 384311