[sr-dev] git:5.2:ddc0073c: cdp: fix two errors from coverty scan (missing check, var initialization)