From 134e02f7e90d37a3056198d8ba374e0271415d15 Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Sun, 5 Apr 2015 15:18:48 +0000 Subject: [PATCH] com_addblob(): Return negative on errors --- blob.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/blob.c b/blob.c index ea746072..6e48c487 100644 --- a/blob.c +++ b/blob.c @@ -374,13 +374,12 @@ static int com_addblob_callback(struct osl_table *table, int fd, afs_event(BLOB_ADD, NULL, table); out: if (ret < 0) - msg_len = xasprintf(&msg, "could not add %s: %s\n", name, - para_strerror(-ret)); + msg_len = xasprintf(&msg, "cannot add %s\n", name); else msg_len = xasprintf(&msg, "added %s as id %u\n", name, id); pass_buffer_as_shm(fd, SBD_OUTPUT, msg, msg_len); free(msg); - return 0; + return ret; } /* Write input from fd to dynamically allocated buffer, but maximal 10M. */ -- 2.39.5