hook_block visibility
When the block visibility is set to 2, $block[0]['pages'] needs to be a string that can be passed to drupal_eval() as first argument. In fact, the code which handles the block visibility is the following one.

  // Match path if necessary
  if ($block-&gt;pages) {
    if ($block-&gt;visibility &lt; 2) {
      $path = drupal_get_path_alias($_GET['q']);
      // Compare with the internal and path alias (if any).
      $page_match = drupal_match_path($path, $block-&gt;pages);
      if ($path != $_GET['q']) {
        $page_match = $page_match || drupal_match_path($_GET['q'], $block-&gt;pages);
      }
      // When $block-&gt;visibility has a value of 0, the block is displayed on
      // all pages except those listed in $block-&gt;pages. When set to 1, it
      // is displayed only on those pages listed in $block-&gt;pages.
      $page_match = !($block-&gt;visibility xor $page_match);
    }
    else {
      $page_match = drupal_eval($block-&gt;pages);
    }
  }