Set up Xauthority using a single invokation
diff --git a/unix/vncserver b/unix/vncserver
index 725cbd5..bb95506 100755
--- a/unix/vncserver
+++ b/unix/vncserver
@@ -242,8 +242,10 @@
 
 $cookie = `mcookie`;
 
-system("xauth -f $xauthorityFile add $host:$displayNumber . $cookie");
-system("xauth -f $xauthorityFile add $host/unix:$displayNumber . $cookie"); 
+open(XAUTH, "|xauth -f $xauthorityFile source -");
+print XAUTH "add $host:$displayNumber . $cookie\n";
+print XAUTH "add $host/unix:$displayNumber . $cookie\n";
+close(XAUTH);
 
 if ($opt{'-name'}) {
     $desktopName = $opt{'-name'};