Index: openacs-4/tcl/0-acs-init.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/tcl/0-acs-init.tcl,v
diff -u -r1.7.2.1 -r1.7.2.2
--- openacs-4/tcl/0-acs-init.tcl	17 Aug 2015 16:43:55 -0000	1.7.2.1
+++ openacs-4/tcl/0-acs-init.tcl	26 Sep 2015 12:58:09 -0000	1.7.2.2
@@ -9,12 +9,16 @@
 
 namespace eval acs {
     #
+    # Determine, under which server we are running
+    #
+    set ::acs::useNaviServer [expr {[ns_info name] eq "NaviServer"}]
+    #
     # Handling NaviServer deprecated ns_info subcommands. 
     #
-    set ::acs::pageroot [expr {[catch {ns_server pagedir}] ? [ns_info pageroot] : [ns_server pagedir]}]
-    set ::acs::tcllib   [expr {[catch {ns_server tcllib}] ? [ns_info tcllib] : [ns_server tcllib]}]
-    set ::acs::rootdir  [file dirname [string trimright $::acs::tcllib "/"]]
+    set ::acs::pageroot [expr {$::acs::useNaviServer ? [ns_server pagedir] : [ns_info pageroot]}]
+    set ::acs::tcllib   [expr {$::acs::useNaviServer ? [ns_server tcllib] : [ns_info tcllib]}]
     #
+    set ::acs::rootdir  [file dirname [string trimright $::acs::tcllib "/"]]
     set ::acs::useNsfProc [expr {[info commands ::nsf::proc] ne ""}]
 }
 
@@ -53,3 +57,9 @@
 } else {
     ns_log "Error" "$bootstrap_file does not exist. Aborting the OpenACS load process."
 }
+
+# Local variables:
+#    mode: tcl
+#    tcl-indent-level: 4
+#    indent-tabs-mode: nil
+# End:
Index: openacs-4/tcl/zz-postload.tcl
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/tcl/zz-postload.tcl,v
diff -u -r1.6 -r1.6.2.1
--- openacs-4/tcl/zz-postload.tcl	27 Oct 2014 16:42:09 -0000	1.6
+++ openacs-4/tcl/zz-postload.tcl	26 Sep 2015 12:58:10 -0000	1.6.2.1
@@ -51,3 +51,9 @@
 }
 
 nsv_unset ad_after_server_initialization .
+
+# Local variables:
+#    mode: tcl
+#    tcl-indent-level: 4
+#    indent-tabs-mode: nil
+# End: