]> git.mdlowis.com Git - projs/tide.git/commitdiff
fixed bug with buf_fetch
authorMichael D. Lowis <mike@mdlowis.com>
Thu, 6 Sep 2018 02:16:37 +0000 (22:16 -0400)
committerMichael D. Lowis <mike@mdlowis.com>
Thu, 6 Sep 2018 02:16:37 +0000 (22:16 -0400)
lib/buf.c

index df45b608b203156753005412d8af930a457bd22d..3c80c6190fa85e96ab2d5047724c95b10f664f20 100644 (file)
--- a/lib/buf.c
+++ b/lib/buf.c
@@ -580,7 +580,7 @@ char* buf_fetch(Buf* buf, bool (*isword)(Rune), size_t off) {
         buf_selword(buf, isword);
         str = buf_gets(buf);
     } else {
-        str = strdup("");
+        str = buf_gets(buf);
     }
     buf->selection = prev;
     return str;