]> git.wh0rd.org Git - nano.git/commitdiff
Last minute touches on -k code
authorChris Allegretta <chrisa@asty.org>
Thu, 27 Jul 2000 13:03:31 +0000 (13:03 +0000)
committerChris Allegretta <chrisa@asty.org>
Thu, 27 Jul 2000 13:03:31 +0000 (13:03 +0000)
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@133 35c25a1d-7b9e-4130-9fde-d3aeb78583b8

cut.c
po/nano.pot

diff --git a/cut.c b/cut.c
index dbe1b461097e70f8220dda5e198bcccc73fd94ab..8950ccd9fbf6a8d0a1b59101a78229612868c981 100644 (file)
--- a/cut.c
+++ b/cut.c
@@ -366,15 +366,18 @@ int do_uncut_text(void)
 
        if (marked_cut == 2 && current_x != strlen(current->data)) {
            tmp = make_new_node(current);
-           tmp->data = nmalloc(strlen(&current->data[current_x]));
+           tmp->data = nmalloc(strlen(&current->data[current_x]) + 1);
            strcpy(tmp->data, &current->data[current_x]);
            tmp->next = current->next;
            current->next = tmp;
            tmp->prev = current;
            current->data[current_x] = 0;
            current->data = nrealloc(current->data, strlen(current->data) + 1);     
+           current = current->next;
+           current_x = 0;
+           placewewant = 0;
        }
-       renumber(current);
+       renumber(current->prev);
        dump_buffer(fileage);
        dump_buffer(cutbuffer);
        set_modified();
index cf8547d771ef54740c4eac94de6abf201e1b392c..cbab5b7c9db2c4db562e0fe1c38670cb3a7956e4 100644 (file)
@@ -6,7 +6,7 @@
 msgid ""
 msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
-"POT-Creation-Date: 2000-07-27 01:11-0400\n"
+"POT-Creation-Date: 2000-07-27 09:08-0400\n"
 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"