diff options
author | Jim Meyering <jim@meyering.net> | 2006-01-04 07:12:22 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2006-01-04 07:12:22 +0000 |
commit | 27ab46340cc6c6b63424fe42e1045f39e3d4556a (patch) | |
tree | 5d1db7b4efbb1967374f7b8d4d12056bc87943a0 /lib | |
parent | a2fa57b24c635b62d2641504a1d6c8aca7243401 (diff) | |
download | coreutils-27ab46340cc6c6b63424fe42e1045f39e3d4556a.tar.xz |
Merge from glibc.
(fts_open): Avoid function call in MAX macro use.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/fts.c | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -1,6 +1,6 @@ /* Traverse a file hierarchy. - Copyright (C) 2004, 2005 Free Software Foundation, Inc. + Copyright (C) 2004, 2005, 2006 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -241,7 +241,8 @@ fts_open (char * const *argv, #ifndef MAXPATHLEN # define MAXPATHLEN 1024 #endif - if (! fts_palloc(sp, MAX(fts_maxarglen(argv), MAXPATHLEN))) + size_t maxarglen = fts_maxarglen(argv); + if (! fts_palloc(sp, MAX(maxarglen, MAXPATHLEN))) goto mem1; /* Allocate/initialize root's parent. */ |