home
·
contact
·
privacy
projects
/
plomrogue
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Removed unnecessary NULLings of pointers, explained kept ones.
[plomrogue]
/
src
/
client
/
windows.c
diff --git
a/src/client/windows.c
b/src/client/windows.c
index 572fccd8811e9c68127336f0dd2609d8b26c915f..6bde9ef1ce2d5431e70bdabdb1680dd73038b320 100644
(file)
--- a/
src/client/windows.c
+++ b/
src/client/windows.c
@@
-483,8
+483,8
@@
static void draw_wins(struct Win * w)
w->start.x + (x - offset_x), ch);
}
}
w->start.x + (x - offset_x), ch);
}
}
- free(w->winmap);
- w->winmap = NULL;
+ free(w->winmap);
/* NULL so draw_wins.c's try_resize_winmap() may always */
+ w->winmap = NULL;
/* free() it before (re-)allocation, even the first time.*/
memset(&w->winmap_size, 0, sizeof(struct yx_uint16));
if (offset_y > 0)
{
memset(&w->winmap_size, 0, sizeof(struct yx_uint16));
if (offset_y > 0)
{
@@
-734,12
+734,10
@@
extern void free_windb()
free(wc->title);
free_keybindings(wc->kb.kbs);
}
free(wc->title);
free_keybindings(wc->kb.kbs);
}
- free(world.windb.ids);
- world.windb.ids = NULL;
+ free(world.windb.ids);
/* NULL this too since add_win_to_windb() checks */
+ world.windb.ids = NULL;
/* for it to detect its first post-DB-purge round.*/
free(world.windb.wins);
free(world.windb.wins);
- world.windb.wins = NULL;
free(world.windb.order);
free(world.windb.order);
- world.windb.order = NULL;
}
}