Renamed local variable to avoid scope collisions

I'm not sure if C++ vars are scoped into {} blocks, but in ported code that is an issue. It's easier to have vars names unique. Does not harm anyone I guess? ;-)