--- menu_stp.dev-patched/menu_stp.module	2012-07-12 10:00:16.000000000 -0700
+++ menu_stp/menu_stp.module	2012-07-12 10:00:34.000000000 -0700
@@ -211,7 +211,7 @@
   $menus = array();
   
   // Get root menu items.
-  $result = db_query("SELECT ml.mlid FROM menu_stp_menu_roles ms INNER JOIN menu_links AS ml ON ml.menu_name = ms.menu_name where ms.rid IN (" . db_placeholders($rids, 'int') . ")", $rids);
+  $result = db_query("SELECT DISTINCT mlid FROM {menu_stp_roles} WHERE rid IN (" . db_placeholders($rids, 'int') . ")", $rids);
   while($row = db_fetch_object($result)) {
     if (!empty($row->mlid)) {
       $link = _menu_stp_link_load($row->mlid);
