Fixed perl warnings