diff options
-rw-r--r-- | src/or/consdiff.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/or/consdiff.c b/src/or/consdiff.c index 16933deb89..c33bad1940 100644 --- a/src/or/consdiff.c +++ b/src/or/consdiff.c @@ -742,7 +742,7 @@ apply_ed_diff(const smartlist_t *cons1, const smartlist_t *diff, } /* Add unchanged lines. */ - for (; j > end; --j) { + for (; j && j > end; --j) { const char *cons_line = smartlist_get(cons1, j-1); smartlist_add(cons2, tor_strdup(cons_line)); } |