unused Brisk::lock_data unlock_data static methods removed
authorMatteo Nastasi (mop) <nastasi@alternativeoutput.it>
Thu, 26 Jun 2014 06:25:16 +0000 (08:25 +0200)
committerMatteo Nastasi (mop) <nastasi@alternativeoutput.it>
Thu, 26 Jun 2014 06:25:16 +0000 (08:25 +0200)
web/Obj/brisk.phh
web/Obj/user.phh
web/briskin5/Obj/briskin5.phh
web/index_wr.php

index 9e0eb12..437389a 100644 (file)
@@ -2255,28 +2255,6 @@ class Brisk
       return (FALSE);
   }
 
-  static function lock_data($is_exclusive)
-  {
-      if (($res = file_lock(FTOK_PATH."/main", $is_exclusive)) != FALSE) {
-          self::$delta_t = microtime(TRUE);
-          log_lock("LOCK   room         [".self::$delta_t."]");
-          
-          return ($res);
-      }
-
-      return (FALSE);
-  }
-  
-  static function unlock_data($res)
-  {
-    GLOBAL $sess; 
-    
-    log_lock("UNLOCK room         [".(microtime(TRUE) - (self::$delta_t))."]");
-
-    file_unlock($res);
-  }
-
-
   function standup_content($user)
   {
     $ret = "";
index d3eaffd..e06c681 100644 (file)
@@ -691,7 +691,6 @@ class User {
           log_rd2("NEWSTAT: ".$this->stat);
       } /* if ($this->rd_step == -1) { */
       else {
-          /* $sem = Brisk::lock_data(FALSE); */
           $S_load_stat['rU_heavy']++;
           
           if ($this->rd_step < $this->step) {
@@ -699,7 +698,6 @@ class User {
                   if ($this->rd_step + COMM_N < $this->step) {
                       if (($this->rd_stat != $this->stat)) {
                           $to_stat = $this->stat;
-                          /* Brisk::unlock_data($sem); */
                           log_load("RESYNC");
                           printf("xXx USER::MAINCHECK2 [%s]\n", get_class($this));
                           return ($this->page_sync($this->sess, ($to_stat == "table" ? "briskin5/index.php" : "index.php"), $this->table, $this->table_token));
@@ -745,8 +743,6 @@ class User {
                   } /* if ($this->the_end == TRUE) { ... */
               } /* if ($this->the_end == TRUE) { ... */
           } /* if ($this->rd_step < $this->step) { */
-          
-          /* Brisk::unlock_data($sem); */
       }  /* else of if ($this->rd_step == -1) { */
       
     
index ce0fa1d..46fb944 100644 (file)
@@ -1079,7 +1079,6 @@ class Bin5_user extends User {
           $this->rd_step  = $this->step;
       } /* if ($this->rd_step == -1) { */
       else {
-          /* $sem = Brisk::lock_data(FALSE); */
           $S_load_stat['rU_heavy']++;
 
           if ($this->rd_step < $this->step) {
@@ -1087,7 +1086,6 @@ class Bin5_user extends User {
                   if ($this->rd_step + COMM_N < $this->step) {
                       if ($this->rd_stat != $this->stat) {
                           $to_stat = $this->stat;
-                          /* Brisk::unlock_data($sem); */
                           log_load("RESYNC");
                           printf("xXx BIN5_USER::MAINCHECK\n");
                           return ($this->page_sync($this->sess, ($to_stat == "table" ? "index.php" : "../index.php"), $this->table, $this->table_token));
@@ -1136,7 +1134,6 @@ class Bin5_user extends User {
               } /* if ($this->the_end == TRUE) { ... */
           } /* if ($this->rd_step < $this->step) { */
 
-          /* Brisk::unlock_data($sem); */
       }  /* else of if ($this->rd_step == -1) { */
 
 
index 2977049..9fed7de 100644 (file)
@@ -853,8 +853,6 @@ function index_wr_main(&$brisk, $remote_addr_full, $get, $post, $cookie)
         }
     }
     
-/* Brisk::unlock_data($sem); */
-/* exit; */
     return (FALSE);
 }
 ?>