[wp-hackers] Cron-code

Robert Deaton false.hopes at gmail.com
Sun Mar 5 01:25:28 GMT 2006


Okay, been looking at the cron code, as I had an idea for something I
wanted to write up and submit as a patch. However, I'm at a loss
looking at some of the code, and hopefully someone can tell me I'm an
idiot and slap me in the head with a stick. First off, I don't see
anywhere in the code where the hook would be fired, a function called,
or anything, I'm at a complete loss. Second, I'm 90% certain this is a
bug:

function wp_clear_scheduled_hook($hook) {
	while($timestamp = next_scheduled('scheduled_hook'))
		wp_unschedule_event($timestamp, 'scheduled_hook');
}

Shouldn't those 'scheduled_hook' strings actually be the $hook that's
being passed in? How would we unschedule an event like that, if
they're stored by an arbitrary hook name?

--
--Robert Deaton
http://somethingunpredictable.com


More information about the wp-hackers mailing list