Sounds like the micro switch on the socket isn't working. Perhaps some grit lodged under it.. Try rapidly pushing in/pulling out the headphone plug. Look in the hole for foreign object. Blow into the hole with canned air or similar. If nothing works, take it to repair shop where they can disassemble it and clean the switch properly...