Make Apache play nice with regen rmdom'ing
authoradamch <adamch>
Sat, 17 Nov 2007 19:26:18 +0000 (19:26 +0000)
committeradamch <adamch>
Sat, 17 Nov 2007 19:26:18 +0000 (19:26 +0000)
src/plugins/apache.sml

index 765d696..132f479 100644 (file)
@@ -256,7 +256,9 @@ val () = Slave.registerFileHandler (fn fs =>
                                                                            file = #file spl}
 
                                                   val user = findVhostUser (#file fs)
-                                                  val oldUser = findVhostUser realVhostFile
+                                                  val oldUser = case #action fs of
+                                                                    Slave.Delete false => user
+                                                                  | _ => findVhostUser realVhostFile
                                               in
                                                   if (oldUser = NONE andalso #action fs <> Slave.Add)
                                                      orelse (user = NONE andalso not (Slave.isDelete (#action fs))) then