[gnome-builder] vala-pack: initialize before notifying callees



commit 0a4627a4d099f0f2586e5e831175e29c476ad996
Author: Christian Hergert <chergert redhat com>
Date:   Thu Apr 25 23:55:53 2019 -0700

    vala-pack: initialize before notifying callees

 src/plugins/vala-pack/ide-vala-client.vala | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)
---
diff --git a/src/plugins/vala-pack/ide-vala-client.vala b/src/plugins/vala-pack/ide-vala-client.vala
index 5fd8b7643..3c3abeb09 100644
--- a/src/plugins/vala-pack/ide-vala-client.vala
+++ b/src/plugins/vala-pack/ide-vala-client.vala
@@ -118,13 +118,6 @@ namespace Ide
                        rpc_client = new Jsonrpc.Client (stream);
                        rpc_client.set_use_gvariant (true);
 
-                       GetContextCB cb = null;
-                       lock (get_client) {
-                               while ((cb = get_client.pop_head ()) != null) {
-                                       cb.source_func ();
-                               }
-                       }
-
                        var @params = Jsonrpc.Message.@new (
                                "rootUri", Jsonrpc.Message.PutString.create (root_uri.get_uri ()),
                                "rootPath", Jsonrpc.Message.PutString.create (root_uri.get_path ()),
@@ -133,6 +126,13 @@ namespace Ide
                        );
 
                        rpc_client.call_async.begin ("initialize", params, null);
+
+                       GetContextCB cb = null;
+                       lock (get_client) {
+                               while ((cb = get_client.pop_head ()) != null) {
+                                       cb.source_func ();
+                               }
+                       }
                }
 
                public void buffer_saved (Ide.Buffer buffer) {


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