From 6ee257920dd4ca97146407adf1030d7249366846 Mon Sep 17 00:00:00 2001 From: Arun Prakash Jana Date: Tue, 5 May 2020 17:14:42 +0530 Subject: Fix context range check --- src/nnn.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/nnn.c b/src/nnn.c index e646393..f915ca7 100644 --- a/src/nnn.c +++ b/src/nnn.c @@ -4258,7 +4258,7 @@ static void readpipe(int fd, char **path, char **lastname, char **lastdir) ctx = r + 1; } else { ctx = g_buf[0] - '0'; - if (ctx > CTX_MAX) + if (ctx < 0 || ctx > CTX_MAX) return; } -- cgit v1.2.3-70-g09d2