fixed bug that perl 5.8 don't work