[Tarantool-patches] [PATCH 1/2] box: introduce constraint names hash table
Cyrill Gorcunov
gorcunov at gmail.com
Tue Nov 12 17:17:25 MSK 2019
On Tue, Nov 12, 2019 at 05:02:58PM +0300, Roman Khabibov wrote:
> +
> +int
> +space_put_constraint_name(struct space *space, const char *name)
> +{
> + uint32_t len = strlen(name);
> + uint32_t hash = mh_strn_hash(name, len);
> + char *name_copy = malloc(len);
> + memcpy(name_copy, name, len);
What if malloc failed here?
More information about the Tarantool-patches
mailing list