Part of my application copies files to a network share. Periodically, the network share times out when PHP does its copy() bit and the application dies with a fatal error (exceeded maximum execution time).
Is there a way to have it "give up" on the copy BEFORE it hits the maximum execution time so that it can throw an exception or give a nicer message to the user (and not clutter my error logs!)?