minor fixes; thx to dennisjay