Why would you possibly need the second derivative to locate a zero crossing?
All this does is look for consecutive elements of a vector that have different signs.
If you really want to see what it does, read the help for circshift. My re-writing existing help will be a waste of time. Given that, what property do two numbers have if they have different signs? Answer: the product will ALWAYS be negative. So all that line does is look for consecutive elements with opposite signs. (Zero will do too.)