samdb: Fix CID 1034910 Dereference before null check