diff options
author | Mattias Andrée <maandree@operamail.com> | 2014-12-08 19:34:26 +0100 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2014-12-08 19:34:26 +0100 |
commit | 3e07c8b1657e28f19072b430936e88be040fb319 (patch) | |
tree | 079b9c8b4669873578cce9eccd79d53c89467a1f /src/libmdsserver | |
parent | m + make sure we never lose errno (diff) | |
download | mds-3e07c8b1657e28f19072b430936e88be040fb319.tar.gz mds-3e07c8b1657e28f19072b430936e88be040fb319.tar.bz2 mds-3e07c8b1657e28f19072b430936e88be040fb319.tar.xz |
rename pfail to fail
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to 'src/libmdsserver')
-rw-r--r-- | src/libmdsserver/client-list.c | 2 | ||||
-rw-r--r-- | src/libmdsserver/linked-list.c | 4 | ||||
-rw-r--r-- | src/libmdsserver/macros.h | 4 | ||||
-rw-r--r-- | src/libmdsserver/mds-message.c | 2 | ||||
-rw-r--r-- | src/libmdsserver/util.c | 2 |
5 files changed, 7 insertions, 7 deletions
diff --git a/src/libmdsserver/client-list.c b/src/libmdsserver/client-list.c index 1bcaa72..ff3ffe2 100644 --- a/src/libmdsserver/client-list.c +++ b/src/libmdsserver/client-list.c @@ -116,7 +116,7 @@ int client_list_clone(const client_list_t* restrict this, client_list_t* restric return 0; - pfail: + fail: saved_errno = errno; free(new_clients); return errno = saved_errno, -1; diff --git a/src/libmdsserver/linked-list.c b/src/libmdsserver/linked-list.c index d17ba8b..7756d90 100644 --- a/src/libmdsserver/linked-list.c +++ b/src/libmdsserver/linked-list.c @@ -145,7 +145,7 @@ int linked_list_clone(const linked_list_t* restrict this, linked_list_t* restric return 0; - pfail: + fail: saved_errno = errno; free(new_values); free(new_next); @@ -221,7 +221,7 @@ int linked_list_pack(linked_list_t* restrict this) return 0; - pfail: + fail: saved_errno = errno; free(vals); free(new_next); diff --git a/src/libmdsserver/macros.h b/src/libmdsserver/macros.h index 84b6060..fc47e0a 100644 --- a/src/libmdsserver/macros.h +++ b/src/libmdsserver/macros.h @@ -379,13 +379,13 @@ /** - * Go to the label `pfail` if a condition is met + * Go to the label `fail` if a condition is met * * @param ... The condition */ #define fail_if(...) \ if (__VA_ARGS__) \ - do { fprintf(stderr, "failure at %s:%i\n", __FILE__, __LINE__); goto pfail; } while (0) + do { fprintf(stderr, "failure at %s:%i\n", __FILE__, __LINE__); goto fail; } while (0) /** diff --git a/src/libmdsserver/mds-message.c b/src/libmdsserver/mds-message.c index d616355..4075f57 100644 --- a/src/libmdsserver/mds-message.c +++ b/src/libmdsserver/mds-message.c @@ -545,7 +545,7 @@ int mds_message_unmarshal(mds_message_t* restrict this, char* restrict data) return 0; - pfail: + fail: return -1; } diff --git a/src/libmdsserver/util.c b/src/libmdsserver/util.c index 70faf3d..2e72229 100644 --- a/src/libmdsserver/util.c +++ b/src/libmdsserver/util.c @@ -369,7 +369,7 @@ pid_t uninterruptable_waitpid(pid_t pid, int* restrict status, int options) /* Don't let the CPU catch fire! */ errno = EINTR; } - pfail: + fail: return rc; } |