--- a/src/main.c
+++ b/src/main.c
@@ -288,6 +288,28 @@
 }
 
 static void
+filer_close(const char *dir)
+{
+    const char *args[4];
+
+    args[0] = "rox";
+    args[1] = "-D";
+    args[2] = dir;
+    args[3] = NULL;
+    g_spawn_async(NULL, (char **) args, NULL, G_SPAWN_SEARCH_PATH,
+            NULL, NULL, NULL, NULL);
+}
+
+static void
+filer_close_device(GduDevice *dev)
+{
+    const char *path = gdu_device_get_mount_path(dev);
+    
+    if (path && path[0])
+        filer_close(path);
+}
+
+static void
 mount_complete(GduDevice *device, char *mount_point,
         GError *error, AddedDeviceData *add)
 {
@@ -410,6 +432,7 @@
 static void
 unmount_clicked(AddedDeviceData *add, gpointer widget)
 {
+    filer_close_device(add->dev);
     add->mounting = TRUE;
     show_mount_status(add);
     gdu_device_op_filesystem_unmount(add->dev,
@@ -421,6 +444,7 @@
 {
     GduDevice *dev;
     
+    filer_close_device(add->dev);
     add->mounting = TRUE;
     show_mount_status(add);
     if (gdu_device_drive_get_is_media_ejectable(add->dev))