]> arthur.barton.de Git - netatalk.git/commitdiff
Merge master
authorFrank Lahm <franklahm@googlemail.com>
Sat, 17 Mar 2012 21:18:14 +0000 (22:18 +0100)
committerFrank Lahm <franklahm@googlemail.com>
Sat, 17 Mar 2012 21:18:14 +0000 (22:18 +0100)
1  2 
etc/cnid_dbd/cnid_metad.c
etc/cnid_dbd/main.c
libatalk/acl/uuid.c

index a264bd8874eb2127193f620b8df1813a3e216f66,f44d70b89b9c7c905f372ed15a3b9eb0074a4d88..5230b741b02b1aa7b76876d25ad2f7531eee3eab
@@@ -113,10 -109,10 +113,10 @@@ static uint maxvol
  #define DEFAULTPORT  "4700"
  
  struct server {
 -    struct volinfo *volinfo;
 +    char *v_path;
      pid_t pid;
      time_t tm;                    /* When respawned last */
-     int count;                    /* Times respawned in the last TESTTIME secondes */
+     unsigned int count;           /* Times respawned in the last TESTTIME secondes */
      int control_fd;               /* file descriptor to child cnid_dbd process */
  };
  
@@@ -550,9 -568,13 +555,13 @@@ int main(int argc, char *argv[]
              if (WIFEXITED(status)) {
                  LOG(log_info, logtype_cnid, "cnid_dbd[%i] exited with exit code %i",
                      pid, WEXITSTATUS(status));
+             } else {
+                 /* cnid_dbd did a clean exit probably on idle timeout, reset bookkeeping */
+                 srv[i].tm = 0;
+                 srv[i].count = 0;
              }
 -            if (WIFSIGNALED(status)) {
 -                LOG(log_info, logtype_cnid, "cnid_dbd[%i] received signal %i",
 +            else if (WIFSIGNALED(status)) {
 +                LOG(log_info, logtype_cnid, "cnid_dbd[%i] got signal %i",
                      pid, WTERMSIG(status));
              }
              sigchild = 0;
Simple merge
Simple merge