aboutsummaryrefslogtreecommitdiff
path: root/linux-user/main.c
diff options
context:
space:
mode:
authorAnthony Liguori <aliguori@us.ibm.com>2009-07-09 15:09:27 -0500
committerAnthony Liguori <aliguori@us.ibm.com>2009-07-09 15:09:27 -0500
commit2152390dca9975b1aaaa6f0518ebdd359477905b (patch)
tree142ccb7c60f9eba302a5c35715158121e885fded /linux-user/main.c
parent94c5495dd16ca3311cbc95705e58d28a45899d1d (diff)
parent666bcd913b1f3e4be8f92995c217498e05379493 (diff)
Merge commit 'linux-user/linux-user-for-upstream' into tmp-staging
Diffstat (limited to 'linux-user/main.c')
-rw-r--r--linux-user/main.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/linux-user/main.c b/linux-user/main.c
index 30290a5837..d49605bd44 100644
--- a/linux-user/main.c
+++ b/linux-user/main.c
@@ -2432,6 +2432,7 @@ int main(int argc, char **argv, char **envp)
envlist_t *envlist = NULL;
const char *argv0 = NULL;
int i;
+ int ret;
if (argc <= 1)
usage();
@@ -2636,9 +2637,10 @@ int main(int argc, char **argv, char **envp)
env->opaque = ts;
task_settid(ts);
- if (loader_exec(filename, target_argv, target_environ, regs,
- info, &bprm) != 0) {
- printf("Error loading %s\n", filename);
+ ret = loader_exec(filename, target_argv, target_environ, regs,
+ info, &bprm);
+ if (ret != 0) {
+ printf("Error %d while loading %s\n", ret, filename);
_exit(1);
}