summarylogtreecommitdiffstats
path: root/CVE-2011-4599.patch
diff options
context:
space:
mode:
Diffstat (limited to 'CVE-2011-4599.patch')
-rw-r--r--CVE-2011-4599.patch22
1 files changed, 22 insertions, 0 deletions
diff --git a/CVE-2011-4599.patch b/CVE-2011-4599.patch
new file mode 100644
index 000000000000..0eabb80ab8c7
--- /dev/null
+++ b/CVE-2011-4599.patch
@@ -0,0 +1,22 @@
+Index: icu-4.8.1.1/source/common/uloc.c
+===================================================================
+--- icu-4.8.1.1.orig/source/common/uloc.c 2011-10-18 19:12:40.000000000 -0400
++++ icu-4.8.1.1/source/common/uloc.c 2012-01-21 19:42:18.087577138 -0500
+@@ -1797,7 +1797,7 @@
+ int32_t variantLen = _deleteVariant(variant, uprv_min(variantSize, (nameCapacity-len)), variantToCompare, n);
+ len -= variantLen;
+ if (variantLen > 0) {
+- if (name[len-1] == '_') { /* delete trailing '_' */
++ if (len > 0 && name[len-1] == '_') { /* delete trailing '_' */
+ --len;
+ }
+ addKeyword = VARIANT_MAP[j].keyword;
+@@ -1805,7 +1805,7 @@
+ break;
+ }
+ }
+- if (name[len-1] == '_') { /* delete trailing '_' */
++ if (len > 0 && len <= nameCapacity && name[len-1] == '_') { /* delete trailing '_' */
+ --len;
+ }
+ }