quark

quark web server
git clone git://git.suckless.org/quark
Log | Files | Refs | LICENSE

commit ed8b7e8954d302f73907f1cc302d124443f947aa
parent 01ed0dac83ed27faf5e8dc90c893b1cd0e8a917f
Author: Laslo Hunhold <dev@frign.de>
Date:   Mon,  5 Mar 2018 01:04:51 +0100

Fix a logic error

We want to xor s.host and udsname, so it especially errors out when none
are given.

Diffstat:
Mmain.c | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/main.c b/main.c @@ -201,8 +201,8 @@ main(int argc, char *argv[]) usage(); } - /* allow either host or UNIX-domain socket, force port with host */ - if ((s.host && udsname) || (s.host && !s.port)) { + /* allow host xor UNIX-domain socket, force port with host */ + if ((!s.host == !udsname) || (s.host && !s.port)) { usage(); }