eunue pushed a commit to branch efl-1.13.

http://git.enlightenment.org/core/efl.git/commit/?id=342e6fcd538636b3919224c5ef66ac76baf3c62d

commit 342e6fcd538636b3919224c5ef66ac76baf3c62d
Author: Jaeun Choi <jaeun12.c...@samsung.com>
Date:   Wed Apr 8 21:29:13 2015 +0900

    eina: eina_unicode_utf8_next_get should return 0
    when one of the parameters is NULL to avoid null pointer access.
    it also corresponds to the description in doc.
    
    @fix
---
 src/lib/eina/eina_inline_unicode.x | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/lib/eina/eina_inline_unicode.x 
b/src/lib/eina/eina_inline_unicode.x
index cf9a993..572fc05 100644
--- a/src/lib/eina/eina_inline_unicode.x
+++ b/src/lib/eina/eina_inline_unicode.x
@@ -35,6 +35,8 @@ eina_unicode_utf8_next_get(const char *buf, int *iindex)
    Eina_Unicode r;
    unsigned char d;
 
+   if (!buf || !iindex) return 0;
+
    ind = *iindex;
 
    /* if this char is the null terminator, exit */

-- 


Reply via email to