summaryrefslogtreecommitdiff
path: root/src/nautilus-autorun-software.c
diff options
context:
space:
mode:
authorAlexander Larsson <alexl@redhat.com>2008-01-18 13:34:41 +0000
committerAlexander Larsson <alexl@src.gnome.org>2008-01-18 13:34:41 +0000
commitffe7ba222b43f4c7d06fdf642b1c9f16482e72f0 (patch)
tree35a5fe77932ba99e08e996f35681a8a2dab4b38f /src/nautilus-autorun-software.c
parent15f536095a726694e28b0202c1b528bad80e09b4 (diff)
downloadnautilus-ffe7ba222b43f4c7d06fdf642b1c9f16482e72f0.tar.gz
Fix coding style
2008-01-18 Alexander Larsson <alexl@redhat.com> * libnautilus-private/nautilus-autorun.c: * src/nautilus-autorun-software.c: Fix coding style svn path=/trunk/; revision=13621
Diffstat (limited to 'src/nautilus-autorun-software.c')
-rw-r--r--src/nautilus-autorun-software.c21
1 files changed, 14 insertions, 7 deletions
diff --git a/src/nautilus-autorun-software.c b/src/nautilus-autorun-software.c
index 7c1b5a533..1f6d31c2e 100644
--- a/src/nautilus-autorun-software.c
+++ b/src/nautilus-autorun-software.c
@@ -80,8 +80,9 @@ _check_file (GFile *mount_root, const char *file_path, gboolean must_be_executab
NULL);
if (file_info != NULL) {
if (must_be_executable) {
- if (g_file_info_get_attribute_boolean (file_info, G_FILE_ATTRIBUTE_ACCESS_CAN_EXECUTE))
+ if (g_file_info_get_attribute_boolean (file_info, G_FILE_ATTRIBUTE_ACCESS_CAN_EXECUTE)) {
ret = TRUE;
+ }
} else {
ret = TRUE;
}
@@ -128,8 +129,9 @@ autorun (GMount *mount)
/* TODO */
}
- if (program_to_spawn != NULL)
+ if (program_to_spawn != NULL) {
path_to_spawn = g_file_get_path (program_to_spawn);
+ }
cwd_for_program = g_file_get_path (root);
@@ -142,8 +144,9 @@ autorun (GMount *mount)
}
g_warning ("Cannot find path for program to spawn");
- if (program_to_spawn != NULL)
+ if (program_to_spawn != NULL) {
g_object_unref (program_to_spawn);
+ }
g_free (path_to_spawn);
g_free (cwd_for_program);
}
@@ -231,21 +234,25 @@ main (int argc, char *argv[])
LIBGNOMEUI_MODULE, argc, argv,
NULL, NULL);
- if (argc != 2)
+ if (argc != 2) {
goto out;
+ }
/* instantiate monitor so we get the "unmounted" signal properly */
monitor = g_volume_monitor_get ();
- if (monitor == NULL)
+ if (monitor == NULL) {
goto out;
+ }
file = g_file_new_for_commandline_arg (argv[1]);
- if (file == NULL)
+ if (file == NULL) {
goto out;
+ }
mount = g_file_find_enclosing_mount (file, NULL, NULL);
- if (mount == NULL)
+ if (mount == NULL) {
goto out;
+ }
present_autorun_for_software_dialog (mount);