Index: /trunk/src/VBox/Additions/common/VBoxService/VBoxServiceAutoMount.cpp
===================================================================
--- /trunk/src/VBox/Additions/common/VBoxService/VBoxServiceAutoMount.cpp	(revision 31210)
+++ /trunk/src/VBox/Additions/common/VBoxService/VBoxServiceAutoMount.cpp	(revision 31211)
@@ -81,4 +81,25 @@
 static int VBoxServiceAutoMountSharedFolder(const char *pszShareName, const char *pszMountPoint)
 {
+#ifdef RT_OS_SOLARIS
+    int flags = 0; /* No flags used yet. */
+    int r = mount(pszShareName,
+                  pszMountPoint,
+                  flags,
+                  "vboxsf",
+                  NULL,                     /* char *dataptr */
+                  0,                        /* int datalen */
+                  NULL,                     /* char *optptr */
+                  0);                       /* int optlen */
+    if (r == 0)
+    {
+        VBoxServiceVerbose(0, "VBoxServiceAutoMountWorker: Shared folder \"%s\" was mounted to \"%s\"\n", pszShareName, pszMountPoint);
+    }
+    else
+    {
+        if (errno != EBUSY) /* Share is already mounted? Then skip error msg. */
+            VBoxServiceError("VBoxServiceAutoMountWorker: Could not mount shared folder \"%s\" to \"%s\", error = %s\n",
+                             pszShareName, pszMountPoint, strerror(errno));
+    }
+#else /* !RT_OS_SOLARIS */
     unsigned long flags = MS_NODEV;
     struct vbsf_mount_opts opts =
@@ -100,25 +121,4 @@
     };
 
-#ifdef RT_OS_SOLARIS
-    flags = 0; /* No flags used yet. */
-    int r = mount(pszShareName,
-                  pszMountPoint,
-                  flags,
-                  "vboxsf",
-                  NULL,                     /* char *dataptr */
-                  0,                        /* int datalen */
-                  NULL,                     /* char *optptr */
-                  0);                       /* int optlen */
-    if (r == 0)
-    {
-        VBoxServiceVerbose(0, "VBoxServiceAutoMountWorker: Shared folder \"%s\" was mounted to \"%s\"\n", pszShareName, pszMountPoint);
-    }
-    else
-    {
-        if (errno != EBUSY) /* Share is already mounted? Then skip error msg. */
-            VBoxServiceError("VBoxServiceAutoMountWorker: Could not mount shared folder \"%s\" to \"%s\", error = %s\n",
-                             pszShareName, pszMountPoint, strerror(errno));
-    }
-#else /* !RT_OS_SOLARIS */
     const char *szOptions = { "rw" };
     struct vbsf_mount_info_new mntinf;
