On Sat, Dec 22, 2001 at 07:02:39PM +0100, Sander Striker wrote: > This patch gets mod_dav to register its methods dynamically. > Instead of relying on the fact that a method isn't registered > and comparing method strings, it now registers and compares > method numbers.
Sander and I talked about this via AIM. He's going to do a new patch which fixes ap_method_register(). That function should return the method number if someone has already registered the method (which could easily happen across modules). Second, he's going to switch the DAV_M_ constants into an enumerated value. Overall, the patch looks great. It really cleans up dav_handler(), and the integer checks will be slightly faster (not that it matters right there, tho). For those unaware of the problem: with the introduction of the method registry, at some point, the server started using registered method numbers rather than M_INVALID for the unknown methods. In particular, this would happen as a result of a Limit(Except) referring to a new method and registering it. dav_handler() would then get a method number it doesn't understand; in particular, it wouldn't get M_INVALID for "REPORT" and it wouldn't ever respond to that method. Cheers, -g -- Greg Stein, http://www.lyra.org/
