summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Golle <daniel@makrotopia.org>2021-07-24 00:14:57 +0100
committerDaniel Golle <daniel@makrotopia.org>2021-07-24 00:27:06 +0100
commita846c6b98d59b55f1e761ffc5aa75077f6944689 (patch)
tree89c6725c94dd9c47ed472d47f83cb58c5f809cd4
parent5114595bc37e441a905db6b05b4487ad67fcb3d1 (diff)
downloadfstools-a846c6b98d59b55f1e761ffc5aa75077f6944689.tar.gz
blockd: fix length of timeout int passed to ioctl
AUTOFS_IOC_SETTIMEOUT expects a pointer to an 'unsigned long' which will result in out-of-bounds access when passing a pointer to an 'int'. Change type of timeout to 'unsigned long'. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
-rw-r--r--blockd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/blockd.c b/blockd.c
index edca896..bf15f10 100644
--- a/blockd.c
+++ b/blockd.c
@@ -574,7 +574,7 @@ struct uloop_timeout autofs_expire_timer = {
static int autofs_mount(void)
{
- int autofs_timeout = AUTOFS_TIMEOUT;
+ unsigned long autofs_timeout = AUTOFS_TIMEOUT;
int kproto_version;
int pipefd[2];
char source[64];