diff options
author | rbuj <[email protected]> | 2019-08-31 10:18:53 +0200 |
---|---|---|
committer | Robert Antoni Buj Gelonch <[email protected]> | 2019-09-03 18:08:10 +0200 |
commit | 9bd8ff26b6c038bb6d8509bf999f16dfb5408a88 (patch) | |
tree | 51f1215c99ad67107d6317efb616c2a0ab043851 /caja/caja-engrampa.c | |
parent | b37773ded4dd15c7591a2e40e4c2e40ba9341c8f (diff) | |
download | engrampa-9bd8ff26b6c038bb6d8509bf999f16dfb5408a88.tar.bz2 engrampa-9bd8ff26b6c038bb6d8509bf999f16dfb5408a88.tar.xz |
remove build warning: local variable shadows another variable
actions.c:245:24: warning: declaration of ‘dialog’ shadows a previous local [-Wshadow]
caja-engrampa.c:137:17: warning: declaration of ‘file’ shadows a previous local [-Wshadow]
caja-engrampa.c:58:17: warning: declaration of ‘file’ shadows a previous local [-Wshadow]
dlg-add-files.c:120:9: warning: declaration of ‘uri’ shadows a previous local [-Wshadow]
fr-window.c:4935:11: warning: declaration of ‘value’ shadows a previous local [-Wshadow]
Diffstat (limited to 'caja/caja-engrampa.c')
-rw-r--r-- | caja/caja-engrampa.c | 20 |
1 files changed, 5 insertions, 15 deletions
diff --git a/caja/caja-engrampa.c b/caja/caja-engrampa.c index 3113394..5001ff9 100644 --- a/caja/caja-engrampa.c +++ b/caja/caja-engrampa.c @@ -39,26 +39,21 @@ extract_to_callback (CajaMenuItem *item, gpointer user_data) { GList *files, *scan; - CajaFileInfo *file; char *default_dir; char *quoted_default_dir; GString *cmd; files = g_object_get_data (G_OBJECT (item), "files"); - file = files->data; - - default_dir = caja_file_info_get_parent_uri (file); - + default_dir = caja_file_info_get_parent_uri (files->data); quoted_default_dir = g_shell_quote (default_dir); cmd = g_string_new ("engrampa"); g_string_append_printf(cmd," --default-dir=%s --extract", quoted_default_dir); for (scan = files; scan; scan = scan->next) { - CajaFileInfo *file = scan->data; - char *uri, *quoted_uri; + char *uri, *quoted_uri; - uri = caja_file_info_get_uri (file); + uri = caja_file_info_get_uri (scan->data); quoted_uri = g_shell_quote (uri); g_string_append_printf (cmd, " %s", quoted_uri); g_free (uri); @@ -114,15 +109,12 @@ add_callback (CajaMenuItem *item, gpointer user_data) { GList *files, *scan; - CajaFileInfo *file; char *uri, *dir; char *quoted_uri, *quoted_dir; GString *cmd; files = g_object_get_data (G_OBJECT (item), "files"); - file = files->data; - - uri = caja_file_info_get_uri (file); + uri = caja_file_info_get_uri (files->data); dir = g_path_get_dirname (uri); quoted_dir = g_shell_quote (dir); @@ -134,9 +126,7 @@ add_callback (CajaMenuItem *item, g_free (quoted_dir); for (scan = files; scan; scan = scan->next) { - CajaFileInfo *file = scan->data; - - uri = caja_file_info_get_uri (file); + uri = caja_file_info_get_uri (scan->data); quoted_uri = g_shell_quote (uri); g_string_append_printf (cmd, " %s", quoted_uri); g_free (uri); |