synchronized methods to ensure thread safety for underlying SimplePickManager code...
authorjprocter <jprocter@compbio.dundee.ac.uk>
Tue, 6 Mar 2007 12:55:46 +0000 (12:55 +0000)
committerjprocter <jprocter@compbio.dundee.ac.uk>
Tue, 6 Mar 2007 12:55:46 +0000 (12:55 +0000)
git-svn-id: https://svn.lifesci.dundee.ac.uk/svn/repository/trunk@347 be28352e-c001-0410-b1a7-c7978e42abec

src/uk/ac/vamsas/client/simpleclient/SimplePickManager.java

index 7b33f48..8ac5516 100644 (file)
@@ -41,7 +41,7 @@ public class SimplePickManager implements IPickManager {
     \r
   }\r
 \r
-  public void sendMessage(Message message) {\r
+  public synchronized void sendMessage(Message message) {\r
     manager.sendMessage(message);\r
   }\r
   /**\r
@@ -49,7 +49,7 @@ public class SimplePickManager implements IPickManager {
    * passThru is true before passing message on.\r
    * @param message\r
    */\r
-  protected void handleMessage(Message message) {\r
+  protected synchronized void handleMessage(Message message) {\r
     while (!passThru) {\r
       try {\r
         Thread.sleep(5);\r