X-Git-Url: https://plomlompom.com/repos/foo.html?a=blobdiff_plain;f=src%2Fwincontrol.c;h=74c9c2a297d6fc9e0fcca3c1afdd83855cd56e2c;hb=6907fb5902bd50d590b6886e6b30090db5b47444;hp=793b75e2d6205b896656da6ca6cf077189b77e6d;hpb=e6b7840265f17e8934500815030a2fc0553feb81;p=plomrogue
diff --git a/src/wincontrol.c b/src/wincontrol.c
index 793b75e..74c9c2a 100644
--- a/src/wincontrol.c
+++ b/src/wincontrol.c
@@ -15,14 +15,6 @@
-extern void free_win(struct Win * win)
-{
- free(win->_title);
- free(win);
-}
-
-
-
extern struct Win * init_win_from_file(struct World * world, char * w_name,
void (* f) (struct Win *))
{
@@ -54,10 +46,10 @@ extern struct Win * init_win_from_file(struct World * world, char * w_name,
exit_err(fclose(file), world, err);
struct WinMeta * wmeta = world->wins.meta;
- struct Win * w = malloc(sizeof(struct Win));
- init_win(wmeta, w, title, height, width, world, f);
+ struct Win * wp; // = malloc(sizeof(struct Win));
+ init_win(wmeta, &wp, title, height, width, world, f);
free(title);
- return w;
+ return wp;
}