toolbox

Check-in [5d35d9ef93]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:lib: free ressource on dmenu_close()
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 5d35d9ef936767e34ec84f0efaead81dd8e16a1bda9186f9d67506a3bbcd8fd8
User & Date: jef 2019-05-14 07:11:05
Context
2019-05-14
07:11
rss: cleanup libmrss Makefile check-in: 1a8afe23ee user: jef tags: trunk
07:11
lib: free ressource on dmenu_close() check-in: 5d35d9ef93 user: jef tags: trunk
2019-05-09
19:37
xtypekeys: remove project check-in: f89d695f66 user: jef tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/i3radio/i3radio.c.

44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
	while (getline(&line, &linecap, pradios) != -1) {
		str_trim(line);
		dmenu_add(dmenu, line);
	}
	pclose(pradios);
	xfree(line);
	response = dmenu_close(dmenu);
	xfree(dmenu);

	return response;
}

void
notify(const char *msg)
{







<







44
45
46
47
48
49
50

51
52
53
54
55
56
57
	while (getline(&line, &linecap, pradios) != -1) {
		str_trim(line);
		dmenu_add(dmenu, line);
	}
	pclose(pradios);
	xfree(line);
	response = dmenu_close(dmenu);


	return response;
}

void
notify(const char *msg)
{

Changes to src/lib/dmenu.c.

76
77
78
79
80
81
82

83
84
85
		str_trim(line);
	fclose(file);
	if (line && line[0] == '\0') {
		xfree(line);
		line = NULL;
	}
	waitpid(dmenu->pid, NULL, 0);


	return line;
}







>



76
77
78
79
80
81
82
83
84
85
86
		str_trim(line);
	fclose(file);
	if (line && line[0] == '\0') {
		xfree(line);
		line = NULL;
	}
	waitpid(dmenu->pid, NULL, 0);
	xfree(dmenu);

	return line;
}