Permalink
Browse files

Fix session locking on slow running background processes

  • Loading branch information...
A5hleyRich committed Sep 12, 2016
1 parent 281a08a commit 7ea1229da1f9f4107c0b22392ac3df73ab761294
Showing with 3 additions and 0 deletions.
  1. +3 −0 classes/wp-background-process.php
@@ -159,6 +159,9 @@ protected function generate_key( $length = 64 ) {
* the process is not already running.
*/
public function maybe_handle() {
// Don't lock up other requests while processing
session_write_close();
if ( $this->is_process_running() ) {
// Background process already running.
wp_die();

0 comments on commit 7ea1229

Please sign in to comment.