Updated it to work with varnish 4.0.1

Added some more comments and a few tweaks.
Merge pull request #2 from jnerin/master

Updated it to work with varnish 4.0.1