$OpenBSD: patch-mail_app_mozilla_in,v 1.8 2007/06/13 12:06:59 martynas Exp $
--- mail/app/mozilla.in.orig	Wed Sep 21 00:13:05 2005
+++ mail/app/mozilla.in	Wed Jun 13 00:29:03 2007
@@ -92,7 +92,13 @@ moz_pis_startstop_scripts()
 #uncomment for debugging
 #set -x
 
+LIMIT=`ulimit -n`
+if [ $LIMIT -lt 128 -a "${LIMIT}" != "unlimited" ]; then  
+	ulimit -Sn 128
+fi
+
 moz_libdir=%MOZAPPDIR%
+MOZ_PLUGIN_PATH=_LOCALBASE_/lib/mozilla-plugins
 MRE_HOME=%MREDIR%
 
 # Use run-mozilla.sh in the current dir if it exists
@@ -170,7 +176,11 @@ do
   esac
 done
 
-export MRE_HOME
+if [ `_X11BASE_/bin/fc-list | wc -l` -eq 0 ]; then
+	export GDK_USE_XFT=0
+fi
+
+export MOZ_PLUGIN_PATH MRE_HOME
 
 ## Start addon scripts
 moz_pis_startstop_scripts "start"
