Skip to content

Instantly share code, notes, and snippets.

/73007.diff Secret

Created September 6, 2016 01:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/5211c325a1f40625d1cc6a7cd0b29114 to your computer and use it in GitHub Desktop.
Save anonymous/5211c325a1f40625d1cc6a7cd0b29114 to your computer and use it in GitHub Desktop.
Patch for 73007
commit 9e07089626f373d0e7b24b7aeb8b8459aae5f5f8
Author: Stanislav Malyshev <stas@php.net>
Date: Mon Sep 5 18:01:35 2016 -0700
Fix bug #73007: add locale length check
diff --git a/ext/intl/msgformat/msgformat_format.c b/ext/intl/msgformat/msgformat_format.c
index 25c9619..9b6df38 100644
--- a/ext/intl/msgformat/msgformat_format.c
+++ b/ext/intl/msgformat/msgformat_format.c
@@ -117,6 +117,8 @@ PHP_FUNCTION( msgfmt_format_message )
RETURN_FALSE;
}
+ INTL_CHECK_LOCALE_LEN(slocale_len);
+
msgformat_data_init(&mfo->mf_data TSRMLS_CC);
if(pattern && pattern_len) {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment