scc

Simple C99 Compiler
Log | Files | Refs | README | LICENSE

commit adb54b6ee21d7b6c56089de7421f5e731c11912d
parent abe630986636294d50ba567fb73713cb7c219e0c
Author: Quentin Rameau <quinq@fifth.space>
Date:   Mon,  4 Jul 2016 16:15:45 +0200

[driver] fix variables order in outfname() printf()

Diffstat:
driver/posix/scc.c | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/driver/posix/scc.c b/driver/posix/scc.c @@ -159,7 +159,7 @@ outfname(char *path, char *type) newsz = pathln + 1 + strlen(type) + 1; new = xmalloc(newsz); - n = snprintf(new, newsz, "%.*s%c%s", path, pathln, sep, type); + n = snprintf(new, newsz, "%.*s%c%s", pathln, path, sep, type); if (n < 0 || n >= newsz) die("scc: wrong output filename"); if ((tmpfd = mkstemp(new)) < 0 && errno != EINVAL)