From ab89c0c4f51e6b22ec6ba254e753b8b4a91a2096 Mon Sep 17 00:00:00 2001 From: Nico Golde Date: Tue, 12 Jun 2007 11:05:33 +0200 Subject: [PATCH] regression fix --- ii.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/ii.c b/ii.c index 232a7b2..f0c9dcc 100644 --- a/ii.c +++ b/ii.c @@ -3,7 +3,6 @@ * (C)opyright MMV-MMVII Nico Golde * See LICENSE file for license details. */ - #include #include #include @@ -103,8 +102,7 @@ static int open_channel(char *name) { return open(infile, O_RDONLY | O_NONBLOCK, 0); } -static void add_channel(char *name) -{ +static void add_channel(char *name) { Channel *c; int fd; @@ -114,8 +112,8 @@ static void add_channel(char *name) fd = open_channel(name); if(fd == -1) { - perror("ii: cannot create in channel"); - return; + printf("ii: exiting, cannot create in channel: %s\n", name); + exit(EXIT_FAILURE); } c = calloc(1, sizeof(Channel)); if(!c) {