diff options
| author | Přemysl Janouch <p.janouch@gmail.com> | 2015-08-16 21:56:47 +0200 |
|---|---|---|
| committer | Přemysl Janouch <p.janouch@gmail.com> | 2015-08-16 21:56:47 +0200 |
| commit | bb2de1fd488bf8b7660ad578fe331eb50f903e12 (patch) | |
| tree | a5c20306786f9dbf1b3e94cc7541f03120b638f5 | |
| parent | 1a305a1c6b1608219334d7512fc09081c9066c9e (diff) | |
| download | liberty-bb2de1fd488bf8b7660ad578fe331eb50f903e12.tar.gz liberty-bb2de1fd488bf8b7660ad578fe331eb50f903e12.tar.xz liberty-bb2de1fd488bf8b7660ad578fe331eb50f903e12.zip | |
Make an assertion give more information
| -rw-r--r-- | liberty.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -679,7 +679,8 @@ static bool set_blocking (int fd, bool blocking) { int flags = fcntl (fd, F_GETFL); - hard_assert (flags != -1); + if (flags == -1) + exit_fatal ("%s: %s", "fcntl", strerror (errno)); bool prev = !(flags & O_NONBLOCK); if (blocking) |
