Whenever I plug in or unplug my headphones into my computer, it freezes for about 10 seconds before it is able to do anything which is rather annoying. This didn't use to happen though, would anyone know the cause of this or how to fix it?
I faced a similar problem. I had a bluetooth headset and a wired one. Whenever I disconnected my wired one, sometimes the mac tried to connect to the bluetooth headset, and when it was switched off/out of range, the system would hang for sometime.
could be something similar. Can you give the list of speakers/headphones configured on your mac and their order (a screenshot would be convinient)
It is certainly not normal and it is indeed a software problem. Although low level drivers are normally for all users, it wouldn’t harm if you try this either under a new fresh user (just create one, reboot your computer, log in with the new one and do the plug-unplug thing).
Also, you can try rebooting and plugging-unplugging in the login screen. If it also hangs there, then there’s certainly something “odd” about your sound drivers and further investigation (and/or system logs analysis) will be required.
If you have a spare drive, and to make sure there isn’t anything hardware related, you might want to try to install a fresh copy of your OS into that drive and see if it happens there, on the fresh install.
There might be a problem with the headphone’s internal hard/soft as well, so testing on another machine wouldn’t hurt to rule out an external problem.
Happens the same in my MacBook, but I think it is because it is switching the software (OS) to send the sound signal to the speakers or the headphones plug. In my MacBooks takes 3 seconds, maybe in yours is more (10 seconds) because you have a lot of software running in the background.