diff options
| author | 2026-03-02 17:54:04 +0100 | |
|---|---|---|
| committer | 2026-03-02 17:54:18 +0100 | |
| commit | fb2120120ee0b5a0165e4d10ee64dfd7bf01814b (patch) | |
| tree | 73915e0ede0e30cf27a78bd573a58ece8072c6ff /c | |
| parent | f2285400e65dafe730a073b3ca92494d72c7295b (diff) | |
driver: fix -pthread, -U
Diffstat (limited to 'c')
| -rw-r--r-- | c/lex.c | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -2175,7 +2175,11 @@ cpppredef(bool undef, const char *cmd) char line[1024]; struct wbuf wbuf = MEMBUF(line, sizeof line); if (!ppcmdline.p) vinit(&ppcmdline, NULL, 1<<10); - int n = bfmt(&wbuf, "%s %S %s\n", undef ? "#undef" : "#define", cmd, namelen, body); + int n; + if (undef) + n = bfmt(&wbuf, "#undef %S\n", cmd, namelen); + else + n = bfmt(&wbuf, "#define %S %s\n", cmd, namelen, body); assert(n <= sizeof line); vpushn(&ppcmdline, line, n); } |