ITS#7377 mdb_env_init_meta(): Catch calloc error

vl32b
Hallvard Furuseth 9 years ago
parent bc4c177b91
commit e9e3c9fb51
  1. 2
      libraries/liblmdb/mdb.c

@ -3695,6 +3695,8 @@ mdb_env_init_meta(MDB_env *env, MDB_meta *meta)
psize = env->me_psize;
p = calloc(NUM_METAS, psize);
if (!p)
return ENOMEM;
p->mp_pgno = 0;
p->mp_flags = P_META;
*(MDB_meta *)METADATA(p) = *meta;

Loading…
Cancel
Save