Commit 4cc2462e authored by Chris Allegretta's avatar Chris Allegretta
Browse files

Clean-up warnings with -pedantic.


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4555 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
parent 170607b6
No related merge requests found
Showing with 4 additions and 4 deletions
+4 -4
...@@ -79,12 +79,12 @@ bool is_byte(int c) ...@@ -79,12 +79,12 @@ bool is_byte(int c)
return ((unsigned int)c == (unsigned char)c); return ((unsigned int)c == (unsigned char)c);
} }
static void mbtowc_reset(void) void mbtowc_reset(void)
{ {
IGNORE_CALL_RESULT(mbtowc(NULL, NULL, 0)); IGNORE_CALL_RESULT(mbtowc(NULL, NULL, 0));
} }
static void wctomb_reset(void) void wctomb_reset(void)
{ {
IGNORE_CALL_RESULT(wctomb(NULL, 0)); IGNORE_CALL_RESULT(wctomb(NULL, 0));
} }
......
...@@ -1695,7 +1695,6 @@ bool write_file(const char *name, FILE *f_open, bool tmp, append_type ...@@ -1695,7 +1695,6 @@ bool write_file(const char *name, FILE *f_open, bool tmp, append_type
/* The actual file, realname, we are writing to. */ /* The actual file, realname, we are writing to. */
char *tempname = NULL; char *tempname = NULL;
/* The temp file name we write to on prepend. */ /* The temp file name we write to on prepend. */
int backup_cflags;
assert(name != NULL); assert(name != NULL);
...@@ -1758,6 +1757,7 @@ bool write_file(const char *name, FILE *f_open, bool tmp, append_type ...@@ -1758,6 +1757,7 @@ bool write_file(const char *name, FILE *f_open, bool tmp, append_type
char *backupname; char *backupname;
struct utimbuf filetime; struct utimbuf filetime;
int copy_status; int copy_status;
int backup_cflags;
/* Save the original file's access and modification times. */ /* Save the original file's access and modification times. */
filetime.actime = openfile->current_stat->st_atime; filetime.actime = openfile->current_stat->st_atime;
......
...@@ -3173,7 +3173,6 @@ void edit_redraw(filestruct *old_current, size_t pww_save) ...@@ -3173,7 +3173,6 @@ void edit_redraw(filestruct *old_current, size_t pww_save)
fprintf(stderr, "edit_redraw(): line %lu was offscreen, oldcurrent = %lu edittop = %lu", openfile->current->lineno, fprintf(stderr, "edit_redraw(): line %lu was offscreen, oldcurrent = %lu edittop = %lu", openfile->current->lineno,
old_current->lineno, openfile->edittop->lineno); old_current->lineno, openfile->edittop->lineno);
#endif #endif
filestruct *old_edittop = openfile->edittop;
#ifndef NANO_TINY #ifndef NANO_TINY
/* If the mark is on, update all the lines between old_current /* If the mark is on, update all the lines between old_current
...@@ -3181,6 +3180,7 @@ void edit_redraw(filestruct *old_current, size_t pww_save) ...@@ -3181,6 +3180,7 @@ void edit_redraw(filestruct *old_current, size_t pww_save)
* whether we've scrolled up or down) of the edit window. */ * whether we've scrolled up or down) of the edit window. */
if (openfile->mark_set) { if (openfile->mark_set) {
ssize_t old_lineno; ssize_t old_lineno;
filestruct *old_edittop = openfile->edittop;
if (old_edittop->lineno < openfile->edittop->lineno) if (old_edittop->lineno < openfile->edittop->lineno)
old_lineno = old_edittop->lineno; old_lineno = old_edittop->lineno;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment