[mutter] monitor-manager: Remove needless code



commit e1704acda4688074a0a7fd31005a96a28a551c1c
Author: Rui Matos <tiagomatos gmail com>
Date:   Wed Oct 15 15:13:47 2014 +0200

    monitor-manager: Remove needless code
    
    Nothing uses this. Signal handlers have access to the new monitor
    infos built by make_logical_config() .
    
    https://bugzilla.gnome.org/show_bug.cgi?id=738630

 src/backends/meta-monitor-manager.c |    8 ++------
 1 files changed, 2 insertions(+), 6 deletions(-)
---
diff --git a/src/backends/meta-monitor-manager.c b/src/backends/meta-monitor-manager.c
index 59c7154..856da7f 100644
--- a/src/backends/meta-monitor-manager.c
+++ b/src/backends/meta-monitor-manager.c
@@ -149,6 +149,8 @@ make_logical_config (MetaMonitorManager *manager)
         manager->primary_monitor_index = info->number;
     }
 
+  g_free (manager->monitor_infos);
+
   manager->n_monitor_infos = monitor_infos->len;
   manager->monitor_infos = (void*)g_array_free (monitor_infos, FALSE);
 }
@@ -1165,18 +1167,12 @@ meta_monitor_manager_read_current_config (MetaMonitorManager *manager)
 void
 meta_monitor_manager_rebuild_derived (MetaMonitorManager *manager)
 {
-  MetaMonitorInfo *old_monitor_infos;
-
-  old_monitor_infos = manager->monitor_infos;
-
   if (manager->in_init)
     return;
 
   make_logical_config (manager);
 
   g_signal_emit_by_name (manager, "monitors-changed");
-
-  g_free (old_monitor_infos);
 }
 
 void


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]