There was a bug if you picked up a locked (or any) chest items, including gold, could stack into the chest. Effectively your gold would disappear and you probably wouldn't know why.