Save and restore shopts (because I am setting nocasematch)
Merge pull request #1 from kurkale6ka/shopt

Save and restore shopts (because I am setting nocasematch)