2e15b699069d147795f3b4bcdf50aa9d099be9ff
max
  Thu Mar 6 02:31:47 2014 -0800
moving the phoneHome business into cgiApoptosis.c/.h to make it callablefrom cart.c. We need to call it from cart.c as otherwise
cgiApoptosisSetup (originally: phoneHome) will be called after mysql
connections are opened. This leads to "mysql server has gone away" if
any CGI is not faster than the child process forked here. The child will
close all mysql connections of the parent process. With the new setup,
the childi is forked before any mysql connections are opened. Ideally
this would be all done in cheapcgi, but cheapcgi is not in the hg/lib
part of the code.

diff --git src/hg/inc/hdb.h src/hg/inc/hdb.h
index 7b54718..44d03da 100644
--- src/hg/inc/hdb.h
+++ src/hg/inc/hdb.h
@@ -444,30 +444,33 @@
 /* Connect to central database for archives.
  * Free this up with hDisconnectCentralArchive(). */
 
 boolean hHostHasPrefix(char *prefix);
 /* Return TRUE if this is running on web-server with host name prefix */
 
 boolean hIsPrivateHost(void);
 /* Return TRUE if this is running on private (development) web-server.
  * This was originally genome-test as well as hgwdev, however genome-test
  * may be repurposed to direct users to the preview site instead of development site. */
 
 boolean hIsBetaHost(void);
 /* Return TRUE if this is running on beta (QA) web-server.
  * Use sparingly as behavior on beta should be as close to RR as possible. */
 
+boolean hIsBrowserbox();
+/* Return TRUE if this is the browserbox virtual machine */
+
 boolean hIsPreviewHost(void);
 /* Return TRUE if this is running on preview web-server.  The preview
  * server is a mirror of the development server provided for public
  * early access. */
 
 char *hBrowserName();
 /* Return browser name based on host name */
 
 boolean hTrackOnChrom(struct trackDb *tdb, char *chrom);
 /* Return TRUE if track exists on this chromosome. */
 
 struct trackDb *trackDbPolishAfterLinkup(struct trackDb *tdbList, char *db);
 /* Do various massaging that can only be done after parent/child
  * relationships are established. */