ext/readline: Fix [-Wcalloc-transposed-args] compiler warning

Closes GH-14280
This commit is contained in:
Gina Peter Banyard 2024-05-20 15:43:33 +01:00
parent d4accd8b12
commit 0accfd1fe1
No known key found for this signature in database
GPG key ID: 3306078E3194AEBD

View file

@ -456,7 +456,7 @@ char **php_readline_completion_cb(const char *text, int start, int end)
matches = rl_completion_matches(text,_readline_command_generator);
} else {
/* libedit will read matches[2] */
matches = calloc(sizeof(char *), 3);
matches = calloc(3, sizeof(char *));
if (!matches) {
return NULL;
}