Fixed errors in printer