Skip to content

Commit 38880f4

Browse files
committed
fix minor memory leaks introduced by new functionality, update usage/readme info, update todo
1 parent f06b217 commit 38880f4

File tree

5 files changed

+8
-1
lines changed

5 files changed

+8
-1
lines changed

README.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ Options:
2121
-font <fontspec> Font to be used
2222
-bc <colorspec> Background color
2323
-fc <colorspec> Text color
24+
-dc <colorspec> Debug color
25+
-title <title> Set window title
2426
-size <n> Set static font size
2527
-maxsize <n> Set maximum size for scaling
2628
-align <alignspec> Align text

TODO

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
use binary search instead of linear search for maximizer
21
run maximizer in separate thread
32
handle static size fonts
3+
use x resource manager

arguments.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -251,4 +251,5 @@ void args_cleanup(CFG* config){
251251
free(config->bg_color);
252252
free(config->debug_color);
253253
free(config->font_name);
254+
free(config->window_name);
254255
}

x11.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,8 @@ bool x11_init(XRESOURCES* res, CFG* config){
157157
class_hints->res_class="xecho";
158158

159159
XSetWMProperties(res->display, res->main, &window_name, NULL, NULL, 0, NULL, wm_hints, class_hints);
160+
161+
XFree(window_name.value);
160162
XFree(size_hints);
161163
XFree(wm_hints);
162164
XFree(class_hints);

xecho.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ int usage(char* fn){
88
printf("\t-font <fontspec>\t\tSelect font by FontConfig name\n\n");
99
printf("\t-fc <colorspec>\t\t\tSet text color by name or HTML code\n\n");
1010
printf("\t-bc <colorspec>\t\t\tSet background color by name or code\n\n");
11+
printf("\t-dc <colorspec>\t\t\tSet debug color by name or code\n\n");
12+
printf("\t-title <title>\t\t\tSet window title\n\n");
1113
printf("\t-size <n>\t\t\tRender at font size n\n\n");
1214
printf("\t-maxsize <n>\t\t\tLimit font size to n at max\n\n");
1315
printf("\t-align [n|ne|e|se|s|sw|w|nw]\tAlign text\n\n");

0 commit comments

Comments
 (0)