File: 600_CVE-2009-2905.patch

package info (click to toggle)
newt 0.52.2-10%2Betch1
  • links: PTS
  • area: main
  • in suites: etch
  • size: 836 kB
  • ctags: 27
  • sloc: makefile: 186; sh: 5
file content (11 lines) | stat: -rw-r--r-- 353 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
--- textbox.c.old	2009-09-22 11:31:37.000000000 +0000
+++ newt-0.52.2/textbox.c	2009-09-22 11:31:47.000000000 +0000
@@ -177,7 +177,7 @@
 
     if (resultPtr) {
 	/* XXX I think this will work */
-	result = malloc(strlen(text) + (strlen(text) / width) + 2);
+	result = malloc(strlen(text) + (strlen(text) / (width - 1)) + 2);
 	*result = '\0';
     }