Fix potential performance problems reported by findbugs

Reported things are inefficient number instatiantions, so this is very
safe.

Change-Id: If865d3748f79a046b3546249facc29968dd25d2d
Signed-off-by: Robert Varga <rovarga@cisco.com>