diff --git a/hermes.c b/hermes.c index ae107e8..0f11751 100644 --- a/hermes.c +++ b/hermes.c @@ -576,6 +576,7 @@ void editorOpen(char *filepath) { FILE *fp = fopen(filepath, "a+"); if (!fp) die("Open file"); + fseek(fp, 0, SEEK_SET); char *line = NULL; size_t linecap = 0;