sbase

suckless unix tools
git clone git://git.2f30.org/sbase
Log | Files | Refs | README | LICENSE

commit eee182cdd74a1348b9dfb8bce0016b32543f706a
parent 6b45824463ee1a26145b5bbae4973b214bbb3354
Author: Hiltjo Posthuma <hiltjo@codemadness.org>
Date:   Tue,  1 Apr 2014 16:55:37 +0200

cmp: fix missing braces

just a style fix, this doesn't change any behaviour since fp[1] is set to stdin above.

Signed-off-by: Hiltjo Posthuma <hiltjo@codemadness.org>

Diffstat:
Mcmp.c | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/cmp.c b/cmp.c @@ -42,10 +42,10 @@ main(int argc, char *argv[]) enprintf(Error, "fopen %s:", argv[0]); fp[1] = stdin; - if (argc == 2) - fp[1] = fopen(argv[1], "r"); - if (!fp[1]) + if (argc == 2) { + if(!(fp[1] = fopen(argv[1], "r"))) enprintf(Error, "fopen %s:", argv[1]); + } for(n = 1; ; n++) { b[0] = getc(fp[0]);