commit 50bdca394975edbfb4197a60be3892f9c9b345c7 from: Markus Uhlin date: Sat Mar 7 11:31:00 2026 UTC psend_file: added null check commit - 8230b6549c33ee0138d2c836050dba2bd70f0699 commit + 50bdca394975edbfb4197a60be3892f9c9b345c7 blob - 7cbb6086da6fac66bbaa14e5acfa11fa1b3238cc blob + e0a68fa90eddb109a280bf246ee8530bae3c1241 --- FICS/utils.c +++ FICS/utils.c @@ -532,6 +532,11 @@ psend_file(int p, const char *dir, const char *file) parray[p].last_file = NULL; parray[p].last_file_byte = 0L; + if (file == NULL || strcmp(file, "") == 0) { + warnx("%s: error: no file", __func__); + return -1; + } + if (dir) snprintf(fname, sizeof fname, "%s/%s", dir, file); else