From 92befae93dff751d20ece51a6e3db98972c0db71 Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <bensberg@telfort.nl>
Date: Fri, 23 Jun 2017 10:43:52 +0200
Subject: [PATCH] startup: don't mark the buffer as modified when in view mode

---
 src/nano.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/nano.c b/src/nano.c
index a39a866a..8934117e 100644
--- a/src/nano.c
+++ b/src/nano.c
@@ -1177,7 +1177,7 @@ bool scoop_stdin(void)
     terminal_init();
     doupdate();
 
-    if (openfile->totsize > 0)
+    if (!ISSET(VIEW_MODE) && openfile->totsize > 0)
 	set_modified();
 
     return TRUE;
-- 
GitLab