Struggling Sabres beat Sharks 5-4 in shootout