~ubuntu-branches/ubuntu/saucy/nano/saucy

« back to all changes in this revision

Viewing changes to src/text.c

  • Committer: Bazaar Package Importer
  • Author(s): Jordi Mallach
  • Date: 2009-11-16 14:05:28 UTC
  • mfrom: (1.2.3 upstream)
  • Revision ID: james.westby@ubuntu.com-20091116140528-b4ochntdqhku0k0a
Tags: 2.1.99pre1-1
* New upstream prerelease.
* The "Ferraris" release.
* Remove empty /usr/share/nano from nano-tiny.
* Drop 10_browser_floating_point_exception.patch, obsolete.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* $Id: text.c 4407 2009-09-03 05:45:13Z astyanax $ */ 
 
1
/* $Id: text.c 4420 2009-11-11 06:00:33Z astyanax $ */ 
2
2
/**************************************************************************
3
3
 *   text.c                                                               *
4
4
 *                                                                        *
409
409
        for (c = u->cutbuffer, t = openfile->current; c->next != NULL && t->next != NULL; ) {
410
410
 
411
411
#ifdef DEBUG
412
 
        fprintf(stderr, "Advancing, lineno  = %zd, data = \"%s\"\n", t->lineno, t->data);
 
412
        fprintf(stderr, "Advancing, lineno  = %lu, data = \"%s\"\n", (unsigned long) t->lineno, t->data);
413
413
#endif
414
414
            c = c->next;
415
415
            t = t->next;
943
943
    }
944
944
 
945
945
#ifdef DEBUG
946
 
    fprintf(stderr, "fs->current->data = \"%s\", current_x = %zd, u->begin = %d, type = %d\n",
947
 
                        fs->current->data,  fs->current_x, u->begin, current_action);
 
946
    fprintf(stderr, "fs->current->data = \"%s\", current_x = %lu, u->begin = %d, type = %d\n",
 
947
                        fs->current->data,  (unsigned long) fs->current_x, u->begin, current_action);
948
948
    fprintf(stderr, "left add_undo...\n");
949
949
#endif
950
950
    fs->last_action = current_action;
966
966
        return;
967
967
 
968
968
#ifdef DEBUG
969
 
        fprintf(stderr, "action = %d, fs->last_action = %d,  openfile->current->lineno = %zd",
970
 
                action, fs->last_action, openfile->current->lineno);
 
969
        fprintf(stderr, "action = %d, fs->last_action = %d,  openfile->current->lineno = %lu",
 
970
                action, fs->last_action, (unsigned long) openfile->current->lineno);
971
971
        if (fs->current_undo)
972
 
            fprintf(stderr, "fs->current_undo->lineno = %zd\n",  fs->current_undo->lineno);
 
972
            fprintf(stderr, "fs->current_undo->lineno = %lu\n",  (unsigned long) fs->current_undo->lineno);
973
973
        else
974
974
            fprintf(stderr, "\n");
975
975
#endif
989
989
    switch (u->type) {
990
990
    case ADD:
991
991
#ifdef DEBUG
992
 
        fprintf(stderr, "fs->current->data = \"%s\", current_x = %zd, u->begin = %d\n",
993
 
                        fs->current->data,  fs->current_x, u->begin);
 
992
        fprintf(stderr, "fs->current->data = \"%s\", current_x = %lu, u->begin = %d\n",
 
993
                        fs->current->data, (unsigned long) fs->current_x, u->begin);
994
994
#endif
995
995
        len = strlen(u->strdata) + 2;
996
996
        data = nrealloc((void *) u->strdata, len * sizeof(char *));