Clean up useless getnatp() in conv(), nav_map(), tele()
Spotted by the Clang Static Analyzer.
This commit is contained in:
parent
8ededa44f9
commit
8195d5fb88
3 changed files with 0 additions and 5 deletions
|
@ -52,8 +52,6 @@ conv(void)
|
||||||
struct lndstr land;
|
struct lndstr land;
|
||||||
struct nstr_item ni;
|
struct nstr_item ni;
|
||||||
|
|
||||||
|
|
||||||
natp = getnatp(player->cnum);
|
|
||||||
if (!snxtsct(&nstr, player->argp[1]))
|
if (!snxtsct(&nstr, player->argp[1]))
|
||||||
return RET_SYN;
|
return RET_SYN;
|
||||||
uwtoconvert = onearg(player->argp[2], "Number to convert: ");
|
uwtoconvert = onearg(player->argp[2], "Number to convert: ");
|
||||||
|
|
|
@ -278,7 +278,6 @@ nav_map(int x, int y, int show_designations)
|
||||||
{
|
{
|
||||||
char *ptr;
|
char *ptr;
|
||||||
struct nstr_sect ns;
|
struct nstr_sect ns;
|
||||||
struct natstr *np;
|
|
||||||
struct sctstr sect;
|
struct sctstr sect;
|
||||||
int i;
|
int i;
|
||||||
/* Note this is not re-entrant anyway, so we keep the buffers
|
/* Note this is not re-entrant anyway, so we keep the buffers
|
||||||
|
@ -305,7 +304,6 @@ nav_map(int x, int y, int show_designations)
|
||||||
return RET_FAIL;
|
return RET_FAIL;
|
||||||
}
|
}
|
||||||
snxtsct_dist(&ns, x, y, 1);
|
snxtsct_dist(&ns, x, y, 1);
|
||||||
np = getnatp(player->cnum);
|
|
||||||
blankfill(wmapbuf, &ns.range, 1);
|
blankfill(wmapbuf, &ns.range, 1);
|
||||||
while (nxtsct(&ns, §)) {
|
while (nxtsct(&ns, §)) {
|
||||||
ptr = &wmap[ns.dy][ns.dx];
|
ptr = &wmap[ns.dy][ns.dx];
|
||||||
|
|
|
@ -46,7 +46,6 @@ tele(void)
|
||||||
char buf[MAXTELSIZE + 1]; /* UTF-8 */
|
char buf[MAXTELSIZE + 1]; /* UTF-8 */
|
||||||
int n;
|
int n;
|
||||||
|
|
||||||
natp = getnatp(player->cnum);
|
|
||||||
if (*player->argp[0] == 'a') {
|
if (*player->argp[0] == 'a') {
|
||||||
if (getele("everybody", buf) <= 0) {
|
if (getele("everybody", buf) <= 0) {
|
||||||
pr("Announcement aborted\n");
|
pr("Announcement aborted\n");
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue