Solved problem with diagnostic internal function.

Signed-off-by: Luis Lau <luis.laum@gmail.com>