diff options
author | John Keeping <john@keeping.me.uk> | 2014-01-13 02:13:48 (JST) |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2014-01-13 04:15:55 (JST) |
commit | fd31aa693077d0eea1b14a7f44ffe29503e2ad59 (patch) | |
tree | 52a07041e444885764db7001ef34fa44b42aa2ea | |
parent | 1b1974c45e5e23e5527aa43c4d9ece423a13dfdc (diff) | |
download | cgit-fd31aa693077d0eea1b14a7f44ffe29503e2ad59.zip cgit-fd31aa693077d0eea1b14a7f44ffe29503e2ad59.tar.gz |
html: remove redundant htmlfd variable
This is never changed from STDOUT_FILENO, so just use that value
directly.
Signed-off-by: John Keeping <john@keeping.me.uk>
-rw-r--r-- | html.c | 4 |
1 files changed, 1 insertions, 3 deletions
@@ -41,8 +41,6 @@ static const char* url_escape_table[256] = { | |||
41 | "%fe", "%ff" | 41 | "%fe", "%ff" |
42 | }; | 42 | }; |
43 | 43 | ||
44 | static int htmlfd = STDOUT_FILENO; | ||
45 | |||
46 | char *fmt(const char *format, ...) | 44 | char *fmt(const char *format, ...) |
47 | { | 45 | { |
48 | static char buf[8][1024]; | 46 | static char buf[8][1024]; |
@@ -77,7 +75,7 @@ char *fmtalloc(const char *format, ...) | |||
77 | 75 | ||
78 | void html_raw(const char *data, size_t size) | 76 | void html_raw(const char *data, size_t size) |
79 | { | 77 | { |
80 | if (write(htmlfd, data, size) != size) | 78 | if (write(STDOUT_FILENO, data, size) != size) |
81 | die_errno("write error on html output"); | 79 | die_errno("write error on html output"); |
82 | } | 80 | } |
83 | 81 | ||