From 824de078e4bdc752da9559cc64df627028310cc3 Mon Sep 17 00:00:00 2001 From: Elliott Hughes Date: Tue, 15 Dec 2020 13:35:52 -0800 Subject: seq: always xwrite. Pointed out by the compiler combined with glibc's use of __attribute__((__warn_unused_result__)) on write(). --- toys/lsb/seq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'toys/lsb') diff --git a/toys/lsb/seq.c b/toys/lsb/seq.c index fccccd8f..beeaed3f 100644 --- a/toys/lsb/seq.c +++ b/toys/lsb/seq.c @@ -115,7 +115,7 @@ void seq_main(void) ss = flush_toybuf(itoa(ss, ii)); else if (inc<0) for (; ii>=len; ii += inc) ss = flush_toybuf(itoa(ss, ii)); - if (ss != toybuf) write(1, toybuf, ss-toybuf); + if (ss != toybuf) xwrite(1, toybuf, ss-toybuf); return; } -- cgit v1.2.3