b68069c6b54febbc2dba6c0430ed1cd4d28cb21e hiram Mon Jun 25 10:19:49 2012 -0700 setting the wiki track to be read only diff --git src/hg/lib/wikiTrack.c src/hg/lib/wikiTrack.c index 44b7e9b..d074dd1 100644 --- src/hg/lib/wikiTrack.c +++ src/hg/lib/wikiTrack.c @@ -384,46 +384,49 @@ struct errCatch *errCatch = errCatchNew(); if (errCatchStart(errCatch)) { page = fetchEditPage(TEST_EMAIL_VERIFIED); } errCatchEnd(errCatch); if (errCatch->gotError) // we think it is supposed to be there { wikiUp = FALSE; // but it will not respond } errCatchFree(&errCatch); char *loginExpired = NULL; if (page) loginExpired = stringIn(LOGIN_EXPIRED, page->fullText); if (loginExpired == NULL) - userName = wikiUser; /* save result for next time */ + userName = NULL; /* read-only mode enforced 2012-06-22 + * otherwise we would set wikiUser here + * to save result for next time */ } /* see if table exists, create it if it is not yet there */ struct sqlConnection *wikiConn = wikiConnect(); if (! sqlTableExists(wikiConn,WIKI_TRACK_TABLE)) { char *query = wikiTrackGetCreateSql(WIKI_TRACK_TABLE); sqlUpdate(wikiConn, query); freeMem(query); } wikiDisconnect(&wikiConn); if (wikiUp) status = TRUE; /* system is enabled */ } if (wikiUserName) - *wikiUserName = userName; /* returning name indicates logged in */ + *wikiUserName = NULL; /* read-only mode enforced 2012-06-22 + * otherwise we would return userName here */ return status; } /* from hg/lib/wikiTrack.sql */ static char *createString = "CREATE TABLE %s (\n" "bin smallint unsigned not null,\n" "chrom varchar(255) not null,\n" "chromStart int unsigned not null,\n" "chromEnd int unsigned not null,\n" "name varchar(255) not null,\n" "score int unsigned not null,\n" "strand char(1) not null,\n" "db varchar(36) not null,\n"