f0bf933e69
- qemu-user: add device mapper and loopback ioctls, enabling kpatkx OBS-URL: https://build.opensuse.org/package/show/Virtualization/qemu?expand=0&rev=40
38 lines
1.1 KiB
Diff
38 lines
1.1 KiB
Diff
From 7dc45b21c5ef8a9445463f8d3754e502621192a7 Mon Sep 17 00:00:00 2001
|
|
From: Fabio Erculiani <lxnay@sabayon.org>
|
|
Date: Tue, 3 Jan 2012 09:38:35 +0000
|
|
Subject: [PATCH] linux-user: target_argv is placed on ts->bprm->argv and can't be freed()
|
|
|
|
TaskState contains linux_bprm struct which encapsulates argv among
|
|
other things.
|
|
argv might be used around the code and is expected to contain valid
|
|
data. Before this patch, ts->bprm->argv was NULL due to it being
|
|
freed right after loader_exec().
|
|
|
|
Signed-off-by: Fabio Erculiani <lxnay@sabayon.org>
|
|
Acked-by: Alexander Graf <agraf@suse.de>
|
|
Signed-off-by: Alexander Graf <agraf@suse.de>
|
|
---
|
|
linux-user/main.c | 5 -----
|
|
1 files changed, 0 insertions(+), 5 deletions(-)
|
|
|
|
diff --git a/linux-user/main.c b/linux-user/main.c
|
|
index 3ffee40..6a5dfde 100644
|
|
--- a/linux-user/main.c
|
|
+++ b/linux-user/main.c
|
|
@@ -3503,11 +3503,6 @@ int main(int argc, char **argv, char **envp)
|
|
_exit(1);
|
|
}
|
|
|
|
- for (i = 0; i < target_argc; i++) {
|
|
- free(target_argv[i]);
|
|
- }
|
|
- free(target_argv);
|
|
-
|
|
for (wrk = target_environ; *wrk; wrk++) {
|
|
free(*wrk);
|
|
}
|
|
--
|
|
1.6.0.2
|
|
|