libtool-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: libtool 1.5.10: AC_LIBTOOL_SYS_MAX_CMD_LEN causes system crash


From: Albert Chin
Subject: Re: libtool 1.5.10: AC_LIBTOOL_SYS_MAX_CMD_LEN causes system crash
Date: Sat, 15 Jan 2005 08:29:59 -0600
User-agent: Mutt/1.5.6i

On Sat, Jan 15, 2005 at 10:28:01PM +0900, Peter O'Gorman wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> Dr. Hans Ekkehard Plesser wrote:
> |
> | Hi!
> |
> | AC_LIBTOOL_SYS_MAX_CMD_LEN reliably causes a system crash under Tru64 
> Unix,
> | V5.1B-PK4 if the number of length of command line arguments is not limited
> | (one can disable length checking with the proc:exec_disable_arg_limit 
> kernel
> | option).
> |
> | I do not know if there is any explicit command in Tru64 to query the 
> maximum
> | length of the command line.  But if
> |
> | /sbin/sysconfig -q proc exec_disable_arg_limit
> |
> | returns
> |
> | proc:
> | exec_disable_arg_limit = 1
> |
> | then the iterative test for the maximum length MUST NOT be run.  
> Otherwise,
> | the system will crash.  I hope that a corresponding check will be 
> integrated
> | into future versions of libtool.
> 
> Okay to apply (to all branches)?
> 
> ...
>
> from  Guido Draheim  <address@hidden>  (tiny change)
> Index: m4/libtool.m4
> ===================================================================
> RCS file: /cvsroot/libtool/libtool/m4/libtool.m4,v
> retrieving revision 1.154
> diff -u -3 -p -u -r1.154 libtool.m4
> --- m4/libtool.m4 14 Jan 2005 09:20:32 -0000 1.154
> +++ m4/libtool.m4 15 Jan 2005 13:17:02 -0000
> @@ -1163,7 +1163,20 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [d
>      # And add a safety zone
>      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
>      ;;
> - *)
> +  osf*)
> +    # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running 
> configure
> +    # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
> +    # nice to cause kernel panics so lets avoid the loop below.
> +    # First set a reasonable default.
> +    lt_cv_sys_max_cmd_len=16384
> +    # 
> +    if test -x /sbin/sysconfig; then
> +      case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
> +        *1*) lt_cv_sys_max_cmd_len=-1 ;;
> +      esac
> +    fi
> +    ;;

Looks good to me, though you are bypassing the tests completely when
exec_disable_arg_limit isn't present.

-- 
albert chin (address@hidden)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]