From: john at keeping.me.uk (John Keeping)
Subject: [PATCH 1/6] html: remove redundant htmlfd variable
Date: Sun, 12 Jan 2014 17:13:48 +0000 [thread overview]
Message-ID: <29041fe02967a5edab77cc7d522a625db2b1a91f.1389546691.git.john@keeping.me.uk> (raw)
In-Reply-To: <cover.1389546691.git.john@keeping.me.uk>
This is never changed from STDOUT_FILENO, so just use that value
directly.
Signed-off-by: John Keeping <john at keeping.me.uk>
---
html.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/html.c b/html.c
index 903d4b7..f0ee2d6 100644
--- a/html.c
+++ b/html.c
@@ -41,8 +41,6 @@ static const char* url_escape_table[256] = {
"%fe", "%ff"
};
-static int htmlfd = STDOUT_FILENO;
-
char *fmt(const char *format, ...)
{
static char buf[8][1024];
@@ -77,7 +75,7 @@ char *fmtalloc(const char *format, ...)
void html_raw(const char *data, size_t size)
{
- if (write(htmlfd, data, size) != size)
+ if (write(STDOUT_FILENO, data, size) != size)
die_errno("write error on html output");
}
--
1.8.5.226.g0d60d77
next prev parent reply other threads:[~2014-01-12 17:13 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-12 17:13 [RFC/PATCH 0/6] Preparation for more filter types john
2014-01-12 17:13 ` john [this message]
2014-01-12 19:11 ` [PATCH 1/6] html: remove redundant htmlfd variable Jason
2014-01-12 17:13 ` [PATCH 2/6] ui-snapshot: set unused cgit_filter fields to zero john
2014-01-12 17:13 ` [PATCH 3/6] filter: pass extra arguments via cgit_open_filter john
2014-01-12 19:20 ` Jason
2014-01-12 17:13 ` [PATCH 4/6] filter: add fprintf_filter function john
2014-01-12 19:23 ` Jason
2014-01-12 19:35 ` john
2014-01-12 19:40 ` Jason
2014-01-12 17:13 ` [PATCH 5/6] filter: add interface layer john
2014-01-12 17:13 ` [PATCH 6/6] filter: introduce "filter type" prefix john
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=29041fe02967a5edab77cc7d522a625db2b1a91f.1389546691.git.john@keeping.me.uk \
--to=cgit@lists.zx2c4.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).