This is actually difficult to detect. The code sample in the last comment to this post works, however.