From f09d75453cacce464f7443e233b356ce47ffd759 Mon Sep 17 00:00:00 2001 From: David Blacka Date: Sat, 19 Sep 2009 20:21:48 +0000 Subject: [PATCH] work around the ulimit behavior on mac os X git-svn-id: https://svn.verisignlabs.com/jdnssec/tools/trunk@177 4cbd57fe-54e5-0310-bd9a-f30fe5ea5e6e --- bin/jdnssec-dstool | 5 ++++- bin/jdnssec-keygen | 7 +++++-- bin/jdnssec-signzone | 5 ++++- bin/jdnssec-verifyzone | 5 ++++- bin/jdnssec-zoneformat | 5 ++++- 5 files changed, 21 insertions(+), 6 deletions(-) diff --git a/bin/jdnssec-dstool b/bin/jdnssec-dstool index c874637..333cce2 100755 --- a/bin/jdnssec-dstool +++ b/bin/jdnssec-dstool @@ -3,7 +3,10 @@ thisdir=`dirname $0` basedir=`cd $thisdir/..; pwd` -ulimit -n `ulimit -H -n` +ulimit_max=`ulimit -H -n` +if [ $ulimit_max != "unlimited" ]; then + ulimit -n $ulimit_max +fi # set the classpath for i in $basedir/lib/*.jar $basedir/lib/*.zip $basedir/build/lib/*.jar; do diff --git a/bin/jdnssec-keygen b/bin/jdnssec-keygen index 31384fb..d51a40e 100755 --- a/bin/jdnssec-keygen +++ b/bin/jdnssec-keygen @@ -1,9 +1,12 @@ -#! /bin/sh +f#! /bin/sh thisdir=`dirname $0` basedir=`cd $thisdir/..; pwd` -ulimit -n `ulimit -H -n` +ulimit_max=`ulimit -H -n` +if [ $ulimit_max != "unlimited" ]; then + ulimit -n $ulimit_max +fi # set the classpath for i in $basedir/lib/*.jar $basedir/lib/*.zip $basedir/build/lib/*.jar; do diff --git a/bin/jdnssec-signzone b/bin/jdnssec-signzone index e729d31..7ce8b60 100755 --- a/bin/jdnssec-signzone +++ b/bin/jdnssec-signzone @@ -3,7 +3,10 @@ thisdir=`dirname $0` basedir=`cd $thisdir/..; pwd` -ulimit -n `ulimit -H -n` +ulimit_max=`ulimit -H -n` +if [ $ulimit_max != "unlimited" ]; then + ulimit -n $ulimit_max +fi # set the classpath for i in $basedir/lib/*.jar $basedir/lib/*.zip $basedir/build/lib/*.jar; do diff --git a/bin/jdnssec-verifyzone b/bin/jdnssec-verifyzone index b0ca825..dca9aec 100755 --- a/bin/jdnssec-verifyzone +++ b/bin/jdnssec-verifyzone @@ -3,7 +3,10 @@ thisdir=`dirname $0` basedir=`cd $thisdir/..; pwd` -ulimit -n `ulimit -H -n` +ulimit_max=`ulimit -H -n` +if [ $ulimit_max != "unlimited" ]; then + ulimit -n $ulimit_max +fi # set the classpath for i in $basedir/lib/*.jar $basedir/lib/*.zip $basedir/build/lib/*.jar; do diff --git a/bin/jdnssec-zoneformat b/bin/jdnssec-zoneformat index 876e42b..6e0a153 100755 --- a/bin/jdnssec-zoneformat +++ b/bin/jdnssec-zoneformat @@ -3,7 +3,10 @@ thisdir=`dirname $0` basedir=`cd $thisdir/..; pwd` -ulimit -n `ulimit -H -n` +ulimit_max=`ulimit -H -n` +if [ $ulimit_max != "unlimited" ]; then + ulimit -n $ulimit_max +fi # set the classpath for i in $basedir/lib/*.jar $basedir/lib/*.zip $basedir/build/lib/*.jar; do