Error check things

This commit is contained in:
jl777
2019-03-06 00:36:43 -11:00
parent b92ff12efe
commit 5c46f7488e
2 changed files with 20 additions and 3 deletions

View File

@@ -466,7 +466,14 @@ get_item(struct rogue_state *rs,char *purpose, int type)
return NULL;
}
else
{
if ( thing_find(obj) < 0 )
{
fprintf(stderr,"cant find thing.%p in list\n",obj); sleep(3);
return(NULL);
}
return obj;
}
}
}
return NULL;