Index: modules/comment/comment.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/comment/comment.module,v
retrieving revision 1.795
diff -u -p -r1.795 comment.module
--- modules/comment/comment.module	20 Oct 2009 17:33:42 -0000	1.795
+++ modules/comment/comment.module	22 Oct 2009 13:14:05 -0000
@@ -192,7 +192,8 @@ function comment_menu() {
     'title' => 'Approve',
     'page callback' => 'comment_approve',
     'page arguments' => array(1),
-    'access arguments' => array('administer comments'),
+    'access callback' => 'comment_access',
+    'access arguments' => array('approve', 1),
     'type' => MENU_LOCAL_TASK,
     'context' => MENU_CONTEXT_INLINE,
     'file' => 'comment.pages.inc',
@@ -882,16 +883,6 @@ function comment_links($comment, $node) 
   $links = array();
   if ($node->comment == COMMENT_NODE_OPEN) {
     if (user_access('administer comments') && user_access('post comments')) {
-      $links['comment_delete'] = array(
-        'title' => t('delete'),
-        'href' => "comment/$comment->cid/delete",
-        'html' => TRUE,
-      );
-      $links['comment_edit'] = array(
-        'title' => t('edit'),
-        'href' => "comment/$comment->cid/edit",
-        'html' => TRUE,
-      );
       $links['comment_reply'] = array(
         'title' => t('reply'),
         'href' => "comment/reply/$comment->nid/$comment->cid",
@@ -906,13 +897,6 @@ function comment_links($comment, $node) 
       }
     }
     elseif (user_access('post comments')) {
-      if (comment_access('edit', $comment)) {
-        $links['comment_edit'] = array(
-          'title' => t('edit'),
-          'href' => "comment/$comment->cid/edit",
-          'html' => TRUE,
-        );
-      }
       $links['comment_reply'] = array(
         'title' => t('reply'),
         'href' => "comment/reply/$comment->nid/$comment->cid",
@@ -1251,6 +1235,8 @@ function comment_access($op, $comment) {
   if ($op == 'edit') {
     return ($user->uid && $user->uid == $comment->uid && comment_num_replies($comment->cid) == 0) || user_access('administer comments');
   }
+  if ($op == 'approve') {
+    return user_access('administer comments') && $comment->status == COMMENT_NOT_PUBLISHED;
 }
 
 /**
