summaryrefslogtreecommitdiffstats
path: root/kernel/arch/um/os-Linux/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/arch/um/os-Linux/drivers')
-rw-r--r--kernel/arch/um/os-Linux/drivers/ethertap_user.c2
-rw-r--r--kernel/arch/um/os-Linux/drivers/tuntap_user.c6
2 files changed, 4 insertions, 4 deletions
diff --git a/kernel/arch/um/os-Linux/drivers/ethertap_user.c b/kernel/arch/um/os-Linux/drivers/ethertap_user.c
index b39b6696a..6d4918246 100644
--- a/kernel/arch/um/os-Linux/drivers/ethertap_user.c
+++ b/kernel/arch/um/os-Linux/drivers/ethertap_user.c
@@ -105,7 +105,7 @@ static int etap_tramp(char *dev, char *gate, int control_me,
sprintf(data_fd_buf, "%d", data_remote);
sprintf(version_buf, "%d", UML_NET_VERSION);
if (gate != NULL) {
- strcpy(gate_buf, gate);
+ strncpy(gate_buf, gate, 15);
args = setup_args;
}
else args = nosetup_args;
diff --git a/kernel/arch/um/os-Linux/drivers/tuntap_user.c b/kernel/arch/um/os-Linux/drivers/tuntap_user.c
index 14126d917..c2e6e1dad 100644
--- a/kernel/arch/um/os-Linux/drivers/tuntap_user.c
+++ b/kernel/arch/um/os-Linux/drivers/tuntap_user.c
@@ -47,7 +47,7 @@ static void tuntap_del_addr(unsigned char *addr, unsigned char *netmask,
}
struct tuntap_pre_exec_data {
- int stdout;
+ int stdout_fd;
int close_me;
};
@@ -55,7 +55,7 @@ static void tuntap_pre_exec(void *arg)
{
struct tuntap_pre_exec_data *data = arg;
- dup2(data->stdout, 1);
+ dup2(data->stdout_fd, 1);
close(data->close_me);
}
@@ -74,7 +74,7 @@ static int tuntap_open_tramp(char *gate, int *fd_out, int me, int remote,
sprintf(version_buf, "%d", UML_NET_VERSION);
- data.stdout = remote;
+ data.stdout_fd = remote;
data.close_me = me;
pid = run_helper(tuntap_pre_exec, &data, argv);