aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Neukirchen <chneukirchen@gmail.com>2016-07-28 23:10:32 +0200
committerChristian Neukirchen <chneukirchen@gmail.com>2016-07-28 23:10:32 +0200
commit122e0f4426831ceb222ab2c3f7919e1721b30ceb (patch)
treeb83f2348f9b97efe8a0e85dec85b01288da608df
parentf28e1c01581312f4f71abec0ad3c85d480922936 (diff)
downloadmblaze-122e0f4426831ceb222ab2c3f7919e1721b30ceb.tar.gz
seq: blaze822_seq_next: fix mseq -n .
-rw-r--r--seq.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/seq.c b/seq.c
index 261c461..96c24fd 100644
--- a/seq.c
+++ b/seq.c
@@ -263,7 +263,8 @@ blaze822_seq_next(char *map, char *range, struct blaze822_seq_iter *iter)
if (strcmp(range, ".") == 0) {
if (!iter->lines) {
iter->lines = 1;
- iter->start = iter->stop = 0;
+ find_cur(map, iter);
+ iter->start = iter->stop = iter->line = iter->cur + 1;
return strdup(blaze822_seq_cur());
} else {
return 0;