/* Writes buflen char(s) from buf to a file */
static void writecp(const char *buf, const size_t buflen)
{
- if (cfg.pickraw)
- return;
-
- if (!g_cppath[0])
+ if (cfg.pickraw || !*g_cppath)
return;
FILE *fp = fopen(g_cppath, "w");
errexit();
}
- /* Enabling the following will miss files with newlines */
- /*
- * if (copybufpos)
- * pcopybuf[copybufpos - 1] = '\n';
- */
-
copybufpos += xstrlcpy(pcopybuf + copybufpos, path, len);
}
char *argv[EXEC_ARGS_MAX] = {0};
char *cmd = NULL;
- if (!file || !file[0])
+ if (!file || !*file)
return;
/* Swap args if the first arg is NULL and second isn't */