Branch: refs/heads/master Author: Colomban Wendling ban@herbesfolles.org Committer: Colomban Wendling ban@herbesfolles.org Date: Wed, 11 Feb 2015 17:22:55 UTC Commit: 99a509de7e6dce381e8bc23c5d080f8c8e5c5e12 https://github.com/geany/geany/commit/99a509de7e6dce381e8bc23c5d080f8c8e5c5e...
Log Message: ----------- python: Fix out of bounds access on unmatched Cython array declaration
Modified Paths: -------------- tagmanager/ctags/python.c
Modified: tagmanager/ctags/python.c 6 lines changed, 4 insertions(+), 2 deletions(-) =================================================================== @@ -622,9 +622,11 @@ static const char *skipTypeDecl (const char *cp, boolean *is_class) while (*ptr && *ptr != '=' && *ptr != '(' && !isspace(*ptr)) { /* skip over e.g. 'cpdef numpy.ndarray[dtype=double, ndim=1]' */ if(*ptr == '[') { - while(*ptr && *ptr != ']') ptr++; + while (*ptr && *ptr != ']') ptr++; + if (*ptr) ptr++; + } else { + ptr++; } - ptr++; } if (!*ptr || *ptr == '=') return NULL; if (*ptr == '(') {
-------------- This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).