summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2014-03-16 20:02:08 +0100
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2014-03-16 20:02:08 +0100
commite5e577cc30171232ca9a9ca6fd6f97e3d59539a1 (patch)
treefd61994ecbb827a3ce64bb493acb8049c54c2ac7
parenta13a5288214c6dbb25bd8da04057f8ff17750ec1 (diff)
Fix vcs_readlink propagating error returned by console_current_id
* console-client/current-vcs.c (vcs_readlink): Return error returned by `console_current_id' as a negative value.
-rw-r--r--console-client/current-vcs.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/console-client/current-vcs.c b/console-client/current-vcs.c
index f1112f98..fb053799 100644
--- a/console-client/current-vcs.c
+++ b/console-client/current-vcs.c
@@ -59,6 +59,8 @@ vcs_readlink (struct iouser *user, struct node *np, char *buf)
if (ret < 0)
ret = -errno;
}
+ else
+ ret = -ret;
return ret;
}