Index: Source/NSMenu.m
===================================================================
--- Source/NSMenu.m	(revision 26941)
+++ Source/NSMenu.m	(working copy)
@@ -817,7 +817,10 @@
 
       if (actionSelector == 0 || sel_eq([menuItem action], actionSelector))
 	{
-	  if ([[menuItem target] isEqual: anObject])
+	  id target = [menuItem target];
+	  /* NB Check target == anObject so that menu items can be found
+	   *    whose target is the (dynamic) first responder. */
+	  if (target == anObject || [target isEqual: anObject])
 	    {
 	      return i;
 	    }
