/* ==================== W_LoadLumpNum ==================== */ void *W_LoadLumpNum (int lump) { void *buf; if ((unsigned)lump >= (unsigned)numlumps) Error ("W_CacheLumpNum: %i >= numlumps",lump); buf = malloc (W_LumpLength (lump)); W_ReadLumpNum (lump, buf); return buf; }
/* * ==================== * W_LoadLumpNum * ==================== */ void * W_LoadLumpNum(int lump) { void *buf; if ((unsigned)lump >= numlumps) Error("%s: %i >= numlumps", __func__, lump); buf = malloc(W_LumpLength(lump)); W_ReadLumpNum(lump, buf); return buf; }