Skip to content

Commit

Permalink
Removing exception catch
Browse files Browse the repository at this point in the history
  • Loading branch information
ianbarber committed Apr 27, 2011
1 parent 5280d9c commit 65ac587
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 14 deletions.
10 changes: 3 additions & 7 deletions worker/sink.php
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -17,13 +17,9 @@
if($ev) { if($ev) {
$total += $results->recv(); $total += $results->recv();
} else { } else {
try { if($ctrl->recv(ZMQ::MODE_NOBLOCK)) {
if($ctrl->recv(ZMQ::MODE_NOBLOCK)) { echo $total, PHP_EOL;
echo $total, PHP_EOL; exit();
exit();
}
} catch (ZMQException $e) {
//noop
} }
} }
} }
Expand Down
10 changes: 3 additions & 7 deletions worker/work.php
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -20,13 +20,9 @@
$message = $work->recv(); $message = $work->recv();
$sink->send(strlen($message)); $sink->send(strlen($message));
} else { } else {
try { if($ctrl->recv(ZMQ::MODE_NOBLOCK)) {
if($ctrl->recv(ZMQ::MODE_NOBLOCK)) { echo "Got END";
echo "Got END"; exit();
exit();
}
} catch(ZMQException $e) {
// noop
} }
} }
} }

0 comments on commit 65ac587

Please sign in to comment.