Back to OP.."Is the bulb safe to use?" Yes, it is probably OK, but if not it will immediately trip the MCB with a dead short(very unlikely) or simply not work. Obviously you will unplug the lamp this time . However, this still leaves unresolved the flash and possible shock. You'll need to check that the pins in the socket are not loose and the insulation inside is not broken.