mirror of
https://github.com/php/php-src.git
synced 2025-01-22 03:34:19 +08:00
- malloc may fail
This commit is contained in:
parent
434f3654da
commit
c278fb01d0
@ -159,6 +159,9 @@ cacheFetch( char **error, void *key )
|
||||
key_value_t *map;
|
||||
|
||||
map = (key_value_t *)malloc(sizeof(key_value_t));
|
||||
if (map == NULL) {
|
||||
return NULL;
|
||||
}
|
||||
map->key = *(int *)key;
|
||||
map->value = 3;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user