QR method: Fixed compilation issue and warnings.

Use of 'uint' is rejected by some compilers, e.g. Visual Studio.