#3468·pygame

Segmentation fault (core dumped) when executing pygame.mixer.Sound.play() a second time.

Author: MichaelTennantCreated Sep 28, 2022Updated Jul 29, 2026
Labelsbugmixerneeds-op-input

Environment:

  • Operating system Linux Debian Mint
  • Python version 3.6.9
  • PyGame version 2.1.2

Current behavior:

Program exits due to signal SIGSEGV being sent resulting in the error code Segmentation fault (core dumped) occasionally when pygame.mixer.Sound().play(). The error usually occurs the second time pygame.mixer.Sound().play() is executed in the program. The error cannot be caught by a try except block.

Link to the project files here.

Edit: In the simplified code below I have managed to replicate the issue except this time the program crashes the first time pygame.mixer.Sound().play() is sent.