fixed warning for 64bit support - misuse of int & NSNotFound