49ers pummel Chargers to end preseason