As I mentioned I haven't used that sketch so I can't say for sure what it does...
Since it is recommended on the Arduino Yun product page I wouldn't think it would be considered a bad thing by the Arduino people.
If you are having wifi stability issues then some log information would help. I probably won't be much help since mine works but you could search for similar log entries on this forum. Use the YunSerialTerminal and run dmesg right after the wifi connection goes down. If nothing else I can tell you which entries seem likely to be related.
There are reports in the forum of various things routers do causing issues, I think most if not all of them have solutions posted (there are quite a few reposts of issues that have been solved before and don't have much info so you have to sort through a bit of static).