cgmnlm

Unnamed repository; edit this file 'description' to name the repository.
git clone git://code.clttr.info/cgmnlm.git
Log | Files | Refs | README | LICENSE

commit 51e0ff2d1cb166c642729bb0d813b29881d49597
parent 7f9f23b53f7dc7eb739fd9af2f8ed1beb809e702
Author: René Wagner <rwa@clttr.info>
Date:   Sat, 28 May 2022 16:17:07 +0200

fix may uninitiliazed tempfile buffer

Diffstat:
Msrc/gmnlm.c | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gmnlm.c b/src/gmnlm.c @@ -769,6 +769,7 @@ do_prompts(const char *prompt, struct browser *browser) if (url[0]) { fprintf(browser->tty, "=> %s\n", url); char *tempfile; + tempfile = tmpnam(NULL); if (in[0] == 't') { struct gemini_response resp; set_url(browser, url, NULL); @@ -777,7 +778,6 @@ do_prompts(const char *prompt, struct browser *browser) fprintf(stderr, "Error: %s\n", gemini_strerr(res, &resp)); } else { - tempfile = tmpnam(NULL); download_resp(browser->tty, resp, tempfile, url); } gemini_response_finish(&resp);