added gpf
fixed bug