diff options
Diffstat (limited to 'main/getopt.c')
| -rw-r--r-- | main/getopt.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/main/getopt.c b/main/getopt.c index 98aac5326e..4174ec21f2 100644 --- a/main/getopt.c +++ b/main/getopt.c @@ -1,6 +1,6 @@ /* +----------------------------------------------------------------------+ - | PHP Version 5 | + | PHP Version 7 | +----------------------------------------------------------------------+ | Copyright (c) 1997-2015 The PHP Group | +----------------------------------------------------------------------+ @@ -88,8 +88,8 @@ PHPAPI int php_getopt(int argc, char* const *argv, const opt_struct opts[], char } } if ((argv[*optind][0] == '-') && (argv[*optind][1] == '-')) { - char *pos; - int arg_end = strlen(argv[*optind])-1; + const char *pos; + int arg_end = (int)strlen(argv[*optind])-1; /* '--' indicates end of args if not followed by a known long option name */ if (argv[*optind][2] == '\0') { @@ -119,7 +119,7 @@ PHPAPI int php_getopt(int argc, char* const *argv, const opt_struct opts[], char optchr = 0; dash = 0; - arg_start += strlen(opts[php_optidx].opt_name); + arg_start += (int)strlen(opts[php_optidx].opt_name); } else { if (!dash) { dash = 1; |
