Avoid compiler warnings.

(file_mask_dialog): do_background argument shadows do_background()
function; renamed to do_bg.

(label_callback): unitialized variable.

(read_filesystem_list): const char *.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
This commit is contained in:
Andrew Borodin 2010-12-01 15:16:54 +03:00
parent 5891476737
commit 6e6ec057cb
4 changed files with 7 additions and 6 deletions

View File

@ -85,7 +85,7 @@ label_callback (Widget * w, widget_msg_t msg, int parm)
while (TRUE)
{
char *q;
char c;
char c = '\0';
q = strchr (p, '\n');
if (q != NULL)
@ -99,6 +99,7 @@ label_callback (Widget * w, widget_msg_t msg, int parm)
if (q == NULL)
break;
q[0] = c;
p = q + 1;
y++;

View File

@ -912,7 +912,7 @@ char *
file_mask_dialog (FileOpContext * ctx, FileOperation operation,
gboolean only_one,
const char *format, const void *text,
const char *def_text, gboolean * do_background)
const char *def_text, gboolean * do_bg)
{
const size_t FMDY = 13;
const size_t FMDX = 68;
@ -1049,7 +1049,7 @@ file_mask_dialog (FileOpContext * ctx, FileOperation operation,
fmd_widgets[7 - OFFSET].u.input.text = def_text_secure;
ctx->stable_symlinks = FALSE;
*do_background = FALSE;
*do_bg = FALSE;
{
struct stat buf;
@ -1143,7 +1143,7 @@ file_mask_dialog (FileOpContext * ctx, FileOperation operation,
dest_dir = g_strdup ("./");
}
if (val == B_USER)
*do_background = TRUE;
*do_bg = TRUE;
}
return dest_dir;

View File

@ -27,7 +27,7 @@ void file_op_context_destroy_ui (FileOpContext * ctx);
char *file_mask_dialog (FileOpContext * ctx, FileOperation operation,
gboolean only_one,
const char *format, const void *text,
const char *def_text, gboolean * do_background);
const char *def_text, gboolean * do_bg);
FileProgressStatus check_progress_buttons (FileOpContext * ctx);

View File

@ -549,7 +549,7 @@ read_filesystem_list (int need_fs_type, int all_fs)
#ifdef MOUNTED_GETMNTENT2 /* SVR4. */
{
struct mnttab mnt;
char *table = MNTTAB;
const char *table = MNTTAB;
FILE *fp;
int ret;