Update fileinfo.sh

This commit is contained in:
midoks 2022-12-09 22:38:53 +08:00
parent e919fac1d5
commit 6c478be4df
1 changed files with 1 additions and 1 deletions

View File

@ -66,7 +66,7 @@ Install_lib()
if [ "$OSNAME" == 'centos' ];then
FILE_softmagic=$sourcePath/php${version}/ext/${LIBNAME}/libmagic/softmagic.c
FIND_UNDEF_STRNDUP=`cat $FILE_softmagic|grep '#undef strndup'`
if [ "$version" -gt "74" ] && [ "$FIND_C99" == "" ];then
if [ "$version" -gt "74" ] && [ "$FIND_UNDEF_STRNDUP" == "" ];then
sed -i $BAK "s/char \*strndup/#undef strndup\nchar \*strndup/g" $FILE_softmagic
fi
fi