function grabSourceFile
{
cd /tmp/lmpsource
wget $1 > $LOG
baseName=$(basename $1)
tar -xvf $baseName > $LOG
cd $baseName
}
When I call this function The captured output is not going to the log file. The output redirection works fine until I call the function. The $LOG variable is set at the top of the file. I tried echoing statements and they would not print. I am guessing the function captures the output itself? If so how do push the output to the file instead of the console. (The wget above prints to console, while an echo inside the function does nothing.)