You should have the Access denied page rather than Page not found.
Page not found is showed because the privatemsg_thread_load() is returning FALSE to the menu handler. I changed:
privatemsg.module:272

function privatemsg_thread_load($thread_id, $account = NULL, $start = NULL) {
  static $threads = array();
  if ((int)$thread_id > 0) {
    $thread = array('thread_id' => $thread_id);

    if (is_null($account)) {
      global $user;
      $account = drupal_clone($user);
    }

    if (!isset($threads[$account->uid])) {
      $threads[$account->uid] = array();
    }
...

to

function privatemsg_thread_load($thread_id, $account = NULL, $start = NULL) {
  static $threads = array();
  if ((int)$thread_id > 0) {
    $thread = array('thread_id' => $thread_id);

    if (is_null($account)) {
      global $user;
      if ($user->uid === 0) { // if user is anonymus let him fall to access rules rather than the menu handler
        return TRUE;
      }
      $account = drupal_clone($user);
    }

    if (!isset($threads[$account->uid])) {
      $threads[$account->uid] = array();
    }
...

Comments

ptmkenny’s picture

Status: Needs review » Needs work

Please supply a git patch.

ptmkenny’s picture

Issue summary: View changes

adding file/line specs

dunx’s picture

Issue summary: View changes

Solution works fine for anonymous, but still get "not found" for a logged in user who's not got access to the privatemsg. Better than it was though :)

blacklabel_tom’s picture

+1 for this on the 6.x-1.5 version

oadaeh’s picture

Status: Needs work » Closed (won't fix)

This issue is being closed because it is against a branch for a version of Drupal that is no longer supported.
If you feel that this issue is still valid, feel free to re-open and update it (and any possible patch) to work with the 7.x-1.x branch (bug fixes only) or the 7.x-2.x branch.
Thank you.