fd0cbd09083b5b275dbd73671013e3b7ad3b575c
angie
  Wed Sep 2 16:54:21 2015 -0700
Check whether local file "extTools.ra" exists before calling printExtMenuData and showing the keyboard shortcuts for it.

diff --git src/hg/hgTracks/extTools.c src/hg/hgTracks/extTools.c
index 24df191..93db442 100644
--- src/hg/hgTracks/extTools.c
+++ src/hg/hgTracks/extTools.c
@@ -8,33 +8,41 @@
  * See README in this or parent directory for licensing information. */
 
 #include "common.h"
 #include "dystring.h"
 #include "hCommon.h"
 #include "htmshell.h"
 #include "hash.h"
 #include "web.h"
 #include "ra.h"
 #include "hgTracks.h"
 #include "extTools.h"
 #include "hgFind.h"
 #include "obscure.h"
 #include "net.h"
 
+boolean extToolsEnabled()
+/* Return TRUE if we can display the external tools menu. */
+{
+return fileExists("extTools.ra");
+}
+
 void printExtMenuData() 
 /* print the external tools aka "send to" menu entries as a javascript list to stdout */
 {
+if (!extToolsEnabled())
+    return;
 struct extTool *extTools = readExtToolRa("extTools.ra");
 struct extTool *et;
 hPuts("<script>\n");
 hPuts("extTools = [\n");
 for(et = extTools; et != NULL; et = et->next)
     {
     if (et->dbs!=NULL)
         {
         if (!slNameInList(et->dbs, database))
             continue;
         }
     if (et->notDbs!=NULL)
         {
         if (slNameInList(et->notDbs, database))
             continue;