good thing you didnt get hurt
Stupid should hurt.
Being able to fire the weapon while still being in the pocket is one of the advantages of a revolver instead of an auto. This is especially true with the concealed hammer models. I have never tried it myself. I suppose if a person ever had to use this tactic setting your clothes on fire would be the least of your concerns.
Tried this with an old jacket when I was practicing point shooting. Had an old jacket, stuffed snub into pocket (normal carrying place in winter) and did my drills. MUCH harder to point shoot this way, but works and can serve a great purpose in "getting the drop" on the bad dude. Thing is, you gotta move after that first round comes out, becuase if they have a gun, they will begin shooting as well.
After one or two rounds, I would then begin moving, getting the pistol clear of the pocket and begin regular move/shoot. For those claiming stupid should hurt, this is a really good practice with a spin gun for defense. The Goodwill is a great place to get junk jackets for practice. I actually watered the pocket and jacket area down to prevent the fire, as mentioned in the OP.