Small performance tweak -- replace a call to expr.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42941 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Matt Madia 2011-10-29 01:58:39 +00:00
parent 6db5b8c639
commit e2932f63b0

View File

@ -339,7 +339,7 @@ function ContainsSubstring()
local string="$1"
local substring="$2"
local newString=${string/${substring}/''}
if [ ${#string} -eq `expr ${#newString} + ${#substring}` ] ; then
if [ ${#string} -eq $((${#newString} + ${#substring})) ] ; then
return 0
fi
return 1