Fixed errors for gcc