summaryrefslogtreecommitdiffstats
path: root/commands/edit.c
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2014-03-07 09:25:09 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2014-03-07 09:25:09 +0100
commita8a08f88cc8c2c78bcc421cd55144813b081bcec (patch)
tree67e818ea7ce5ab531251467e13fa3ec3e18e11c7 /commands/edit.c
parent2331b1d8e8d7aabe52b4fd65ca200cf8288aec88 (diff)
parentd0343211a27b982c3ef61597b68a6bf76df887af (diff)
downloadbarebox-a8a08f88cc8c2c78bcc421cd55144813b081bcec.tar.gz
barebox-a8a08f88cc8c2c78bcc421cd55144813b081bcec.tar.xz
Merge branch 'for-next/misc'
Conflicts: common/environment.c
Diffstat (limited to 'commands/edit.c')
-rw-r--r--commands/edit.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/commands/edit.c b/commands/edit.c
index 6764e84efd..b0fcf69fdd 100644
--- a/commands/edit.c
+++ b/commands/edit.c
@@ -266,7 +266,7 @@ static int save_file(const char *path)
fd = open(path, O_WRONLY | O_TRUNC | O_CREAT);
if (fd < 0) {
printf("could not open file for writing: %s\n", errno_str());
- return -1;
+ return fd;
}
line = buffer;