Skip to content

Commit

Permalink
minor cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
laruence committed Apr 8, 2020
1 parent beea81d commit 4b4dd9b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion yaf_application.c
Original file line number Diff line number Diff line change
Expand Up @@ -852,7 +852,7 @@ PHP_METHOD(yaf_application, bootstrap) {

ZEND_HASH_FOREACH_STR_KEY(&(ce->function_table), func) {
/* cann't use ZEND_STRL in strncasecmp, it cause a compile failed in VS2009 */
if (strncasecmp(ZSTR_VAL(func), YAF_BOOTSTRAP_INITFUNC_PREFIX, sizeof(YAF_BOOTSTRAP_INITFUNC_PREFIX) - 1)) {
if (strncmp(ZSTR_VAL(func), YAF_BOOTSTRAP_INITFUNC_PREFIX, sizeof(YAF_BOOTSTRAP_INITFUNC_PREFIX) - 1)) {
continue;
}
zend_call_method(&bootstrap, ce, NULL, ZSTR_VAL(func), ZSTR_LEN(func), NULL, 1, dispatcher, NULL);
Expand Down
2 changes: 1 addition & 1 deletion yaf_dispatcher.c
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,7 @@ zend_class_entry *yaf_dispatcher_get_action(zend_string *app_dir, yaf_controller
memcpy(p, "action", sizeof("action"));
} else {
char *p = ZSTR_VAL(lc_name);
memcpy(p, "action", sizeof("action"));
memcpy(p, "action", sizeof("action") - 1);
p += sizeof("action") - 1;
if (UNEXPECTED(YAF_G(name_separator_len))) {
zend_str_tolower_copy(p, YAF_G(name_separator), YAF_G(name_separator_len));
Expand Down

0 comments on commit 4b4dd9b

Please sign in to comment.