Changeset 963
- Timestamp:
- 2000-02-22T11:01:02+13:00 (24 years ago)
- Location:
- trunk/gsdl/src/recpt
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gsdl/src/recpt/buildaction.cpp
r822 r963 30 30 #include "htmlutils.h" 31 31 #include "buildaction.h" 32 #include "gsdlhome.h"33 32 34 33 /////////////// … … 103 102 logout << "The page action does not contain information\n" 104 103 << "about any receptionists. The method set_receptionist\n" 105 << 106 << 104 << "was probably not called from the module which instantiated\n" 105 << "this page action.\n"; 107 106 return; 108 107 } … … 111 110 if (rprotolist == NULL) return; 112 111 113 const recptconf &rcinfo = recpt->get_configinfo ();114 115 112 // build up javascript and HTML code useful in web forms 116 113 text_t first_dirname = ""; … … 193 190 // check to see if the "collection" is writable 194 191 text_t cfg_fname 195 = filename_cat( GSDL_GSDLHOME,"collect",*collist_here,"etc","collect.cfg");192 = filename_cat(gsdlhome, "collect", *collist_here, "etc", "collect.cfg"); 196 193 if (!file_writable(cfg_fname)) 197 194 { … … 276 273 // set macro cfgperm based on whether config file can be read or no 277 274 text_t dirname = (args["bc1dirname"] == "") ? first_dirname : args["bc1dirname"]; 278 text_t cfg_fname = filename_cat( rcinfo.gsdlhome,"collect",dirname,"etc","collect.cfg");275 text_t cfg_fname = filename_cat(gsdlhome, "collect", dirname, "etc", "collect.cfg"); 279 276 text_t cfgperm = (file_writable(cfg_fname)) ? "read/write" : "readonly"; 280 277 disp.setmacro("cfgperm","build",cfgperm); … … 288 285 // read in collect.cfg 289 286 text_t cfg_fname 290 = filename_cat( GSDL_GSDLHOME,"collect",dirname,"etc","collect.cfg");287 = filename_cat(gsdlhome, "collect", dirname, "etc", "collect.cfg"); 291 288 ifstream cfg_ifs (cfg_fname.getcstr(), ios::in | ios::nocreate); 292 289 if (cfg_ifs) … … 323 320 324 321 // read in collect.bld 325 text_t bld_fname = filename_cat( rcinfo.gsdlhome,"log",dirname+".bld");322 text_t bld_fname = filename_cat(gsdlhome, "log", dirname+ ".bld"); 326 323 ifstream bld_ifs (bld_fname.getcstr(), ios::in | ios::nocreate); 327 324 if (bld_ifs) … … 356 353 ostream &logout) { 357 354 355 // make sure we know about a receptionist 356 if (recpt == NULL) { 357 logout << "The page action does not contain information\n" 358 << "about any receptionists. The method set_receptionist\n" 359 << "was probably not called from the module which instantiated\n" 360 << "this page action.\n"; 361 return false; 362 } 358 363 359 364 if (args["bca"] == "newcol") { … … 419 424 outconvertclass &outconvert, ostream &textout, 420 425 ostream &logout) { 426 427 421 428 422 429 … … 448 455 449 456 textout << outconvert << disp << headmess << content << "_build:framefooter_\n"; 450 451 text_t cmd = filename_cat(GSDL_GSDLHOME,"cgi-bin","webpage_buildcol.pl"); 457 text_t cmd = filename_cat(gsdlhome, "cgi-bin", "webpage_buildcol.pl"); 452 458 cmd += " gsdlhome=\""+args["gsdlhome"]+"\" httpbuild=\""+args["httpbuild"]+"\""; 453 459 cmd += " bc1copydata=\""+args["bc1copydata"]+"\""; -
trunk/gsdl/src/recpt/cgiwrapper.cpp
r872 r963 28 28 /* 29 29 $Log$ 30 Revision 1.22 2000/02/21 21:56:46 sjboddie 31 gsdlhome now comes from gsdlsite.cfg 32 30 33 Revision 1.21 2000/01/25 22:45:59 sjboddie 31 34 few changes to get fastcgi to work properly … … 120 123 #include "cgiwrapper.h" 121 124 #include "recptconfig.h" 125 #include "fileutil.h" 122 126 #include <stdlib.h> 123 127 #include <assert.h> 124 125 126 // get GSDL_GSDLHOME127 #include "gsdlhome.h"128 129 128 130 129 #if defined(GSDL_USE_OBJECTSPACE) … … 193 192 194 193 195 static void page_errorsitecfg (const text_t &gsdlhome, const text_t &collection, 196 text_t &errorpage) { 194 static void page_errorsitecfg (text_t &errorpage, int mode) { 197 195 errorpage += "Content-type: text/html\n\n"; 198 196 … … 203 201 errorpage += "<body>\n"; 204 202 errorpage += "<h2>Oops!</h2>\n"; 205 errorpage += "The site.cfg configuration file could not be found. This file\n"; 206 errorpage += "should contain configuration information relating to this\n"; 207 errorpage += "site's setup. "; 208 if (collection.empty()) { 209 errorpage += "As this cgi script is not being run in collection specific mode,\n"; 210 errorpage += "the file should reside at "; 211 errorpage += gsdlhome; 212 errorpage += "/etc/site.cfg.\n"; 213 } else { 214 errorpage += "As this cgi script is being run in collection specific mode,\n"; 215 errorpage += "the file can reside in "; 216 errorpage += gsdlhome; 217 errorpage += "/collect/"; 218 errorpage += collection; 219 errorpage += "/etc/site.cfg or "; 220 errorpage += gsdlhome; 221 errorpage += "/etc/site.cfg.\n"; 203 if (mode == 0) { 204 errorpage += "The gsdlsite.cfg configuration file could not be found. This file\n"; 205 errorpage += "should contain configuration information relating to this\n"; 206 errorpage += "site's setup.\n"; 207 errorpage += "gsdlsite.cfg should reside in the same directory as this executable\n"; 208 } else if (mode == 1) { 209 errorpage += "The gsdlsite.cfg configuration file does not contain a valid gsdlhome\n"; 210 errorpage += "entry.\n"; 211 errorpage += "gsdlsite.cfg resides in the same directory as this executable\n"; 222 212 } 223 213 errorpage += "</body>\n"; … … 237 227 errorpage += "<h2>Oops!</h2>\n"; 238 228 if (collection.empty()) { 229 text_t main_cfg_file = filename_cat (gsdlhome, "etc", "main.cfg"); 239 230 errorpage += "The main.cfg configuration file could not be found. This file\n"; 240 231 errorpage += "should contain configuration information relating to the\n"; 241 232 errorpage += "setup of the interface. As this cgi script is not being run\n"; 242 233 errorpage += "in collection specific mode the file should reside at\n"; 243 errorpage += gsdlhome; 244 errorpage += "/etc/main.cfg.\n"; 234 errorpage += main_cfg_file + ".\n"; 245 235 } else { 246 errorpage += "Neither the collect.cfg or main.cfg configuration files could\n"; 236 text_t collect_cfg_file = filename_cat (gsdlhome, "collect", collection, "etc", "collect.cfg"); 237 text_t main_collect_cfg_file = filename_cat (gsdlhome, "etc", "collect.cfg"); 238 text_t main_cfg_file = filename_cat (gsdlhome, "etc", "main.cfg"); 239 errorpage += "Either the collect.cfg or main.cfg configuration file could\n"; 247 240 errorpage += "not be found. This file should contain configuration information\n"; 248 241 errorpage += "relating to the setup of the interface. As this cgi script is\n"; 249 242 errorpage += "being run in collection specific mode the file should reside\n"; 250 243 errorpage += "at either "; 251 errorpage += gsdlhome; 252 errorpage += "/collect/"; 253 errorpage += collection; 254 errorpage += "/etc/collect.cfg, "; 255 errorpage += gsdlhome; 256 errorpage += "/etc/collect.cfg or "; 257 errorpage += gsdlhome; 258 errorpage += "/etc/main.cfg.\n"; 244 errorpage += collect_cfg_file + ",\n"; 245 errorpage += main_collect_cfg_file + " or " + main_cfg_file + ".\n"; 259 246 } 260 247 errorpage += "</body>\n"; … … 263 250 264 251 265 static void page_errorinit (const text_t & /*gsdlhome*/, text_t &errorpage) {252 static void page_errorinit (const text_t &gsdlhome, text_t &errorpage) { 266 253 errorpage += "Content-type: text/html\n\n"; 267 254 … … 276 263 errorpage += "correctly.\n"; 277 264 278 ifstream initin (GSDL_GSDLHOME "/etc/initout.txt"); 265 text_t init_file = filename_cat (gsdlhome, "etc", "initout.txt"); 266 char *ifile = init_file.getcstr(); 267 ifstream initin (ifile); 268 delete ifile; 279 269 if (initin) { 280 errorpage += "The initialisation error log, " GSDL_GSDLHOME "/etc/initout.txt, contains the\n";270 errorpage += "The initialisation error log, " + init_file + ", contains the\n"; 281 271 errorpage += "following information:\n\n"; 282 272 errorpage += "<pre>\n"; … … 294 284 295 285 } else { 296 errorpage += "Please consult " GSDL_GSDLHOME "/etc/initout.txtfor more information.\n";286 errorpage += "Please consult " + init_file + " for more information.\n"; 297 287 } 298 288 … … 301 291 } 302 292 303 static void page_errorparseargs (const text_t & /*gsdlhome*/, text_t &errorpage) {293 static void page_errorparseargs (const text_t &gsdlhome, text_t &errorpage) { 304 294 errorpage += "Content-type: text/html\n\n"; 305 295 … … 312 302 errorpage += "An error occurred during the parsing of the cgi arguments.\n"; 313 303 314 ifstream errin (GSDL_GSDLHOME "/etc/errout.txt"); 304 text_t error_file = filename_cat (gsdlhome, "etc", "errout.txt"); 305 char *efile = error_file.getcstr(); 306 ifstream errin (efile); 307 delete efile; 315 308 if (errin) { 316 errorpage += "The error log, " GSDL_GSDLHOME "/etc/errout.txt, contains the\n";309 errorpage += "The error log, " + error_file + ", contains the\n"; 317 310 errorpage += "following information:\n\n"; 318 311 errorpage += "<pre>\n"; … … 328 321 329 322 } else { 330 errorpage += "Please consult " GSDL_GSDLHOME "/etc/errout.txtfor more information.\n";323 errorpage += "Please consult " + error_file + " for more information.\n"; 331 324 } 332 325 … … 335 328 } 336 329 337 static void page_errorcgipage (const text_t & /*gsdlhome*/, text_t &errorpage) {330 static void page_errorcgipage (const text_t &gsdlhome, text_t &errorpage) { 338 331 errorpage += "Content-type: text/html\n\n"; 339 332 … … 346 339 errorpage += "An error occurred during the construction of the cgi page.\n"; 347 340 348 ifstream errin (GSDL_GSDLHOME "/etc/errout.txt"); 341 342 text_t error_file = filename_cat (gsdlhome, "etc", "errout.txt"); 343 char *efile = error_file.getcstr(); 344 ifstream errin (efile); 345 delete efile; 349 346 if (errin) { 350 errorpage += "The error log, " GSDL_GSDLHOME "/etc/errout.txt, contains the\n";347 errorpage += "The error log, " + error_file + ", contains the\n"; 351 348 errorpage += "following information:\n\n"; 352 349 errorpage += "<pre>\n"; … … 362 359 363 360 } else { 364 errorpage += "Please consult " GSDL_GSDLHOME "/etc/errout.txtfor more information.\n";361 errorpage += "Please consult " + error_file + " for more information.\n"; 365 362 } 366 363 … … 386 383 // set defaults 387 384 int maxrequests = 10000; 388 recpt.configure ("gsdlhome", GSDL_GSDLHOME);389 385 recpt.configure ("collection", collection); 390 386 recpt.configure ("httpimg", "/gsdl/images"); … … 394 390 395 391 // read in the configuration files. 396 if (!site_cfg_read (recpt, GSDL_GSDLHOME, collection, maxrequests)) { 392 text_t gsdlhome; 393 if (!site_cfg_read (recpt, gsdlhome, maxrequests)) { 397 394 // couldn't find the site configuration file 398 page_errorsitecfg (GSDL_GSDLHOME, collection, errorpage); 399 } else if (!main_cfg_read (recpt, GSDL_GSDLHOME, collection)) { 395 page_errorsitecfg (errorpage, 0); 396 } else if (gsdlhome.empty()) { 397 // no gsdlhome in gsdlsite.cfg 398 page_errorsitecfg (errorpage, 1); 399 } else if (!main_cfg_read (recpt, gsdlhome, collection)) { 400 400 // couldn't find the main configuration file 401 page_errormaincfg ( GSDL_GSDLHOME, collection, errorpage);401 page_errormaincfg (gsdlhome, collection, errorpage); 402 402 } 403 403 404 404 // initialise the library software 405 405 if (errorpage.empty()) { 406 ofstream initout (GSDL_GSDLHOME "/etc/initout.txt"); 406 text_t init_file = filename_cat (gsdlhome, "etc", "initout.txt"); 407 char *iout = init_file.getcstr(); 408 ofstream initout (iout); 409 delete iout; 407 410 if (!recpt.init(initout)) { 408 411 // an error occurred during the initialisation 409 412 initout.close(); 410 page_errorinit( GSDL_GSDLHOME, errorpage);413 page_errorinit(gsdlhome, errorpage); 411 414 } 412 415 initout.close(); … … 523 526 524 527 if (errorpage.empty()) { 525 ofstream errout (GSDL_GSDLHOME "/etc/errout.txt"); 528 text_t error_file = filename_cat (gsdlhome, "etc", "errout.txt"); 529 char *eout = error_file.getcstr(); 530 ofstream errout (eout); 531 delete eout; 526 532 cerr = errout; 527 533 … … 530 536 if (!recpt.parse_cgi_args (argstr, args, errout, fastcgienv)) { 531 537 errout.close (); 532 page_errorparseargs( GSDL_GSDLHOME, errorpage);538 page_errorparseargs(gsdlhome, errorpage); 533 539 } else { 534 540 if (!recpt.produce_cgi_page (args, pageout, errout, fastcgienv)) { 535 541 errout.close (); 536 page_errorcgipage( GSDL_GSDLHOME, errorpage);542 page_errorcgipage(gsdlhome, errorpage); 537 543 } else { 538 544 errout.close (); -
trunk/gsdl/src/recpt/historydb.cpp
r939 r963 28 28 /* 29 29 $Log$ 30 Revision 1.3 2000/02/21 22:01:02 sjboddie 31 gsdlhome now comes from gsdlsite.cfg 32 30 33 Revision 1.2 2000/02/17 02:40:21 sjboddie 31 34 tidied up a bit - fixed a bug (gdbm file wasn't always being closed properly) … … 35 38 36 39 #include "historydb.h" 37 #include "gsdlhome.h"38 40 #include "fileutil.h" 39 41 #include "cgiutils.h" … … 44 46 // returns true on success (in which case historyinfo will contain 45 47 // the information for this history) 46 bool get_history_info (const text_t &userid, text_tarray &historyinfo, ostream &logout) { 47 48 text_t historyfile = filename_cat(GSDL_GSDLHOME, "etc", "history.db"); 48 bool get_history_info (const text_t &userid, text_tarray &historyinfo, 49 const text_t &gsdlhome, ostream &logout) { 50 51 text_t historyfile = filename_cat(gsdlhome, "etc", "history.db"); 49 52 50 53 bool result = false; … … 74 77 75 78 // returns true on success 76 bool set_history_info (const text_t &userid, const text_t &history ) {77 78 text_t historyfile = filename_cat( GSDL_GSDLHOME, "etc", "history.db");79 bool set_history_info (const text_t &userid, const text_t &history, const text_t &gsdlhome) { 80 81 text_t historyfile = filename_cat(gsdlhome, "etc", "history.db"); 79 82 80 83 bool result = false; … … 126 129 127 130 // deletes all a users history 128 bool delete_all_history_info (const text_t &userid ) {129 130 text_t historyfile = filename_cat( GSDL_GSDLHOME, "etc", "history.db");131 bool delete_all_history_info (const text_t &userid, const text_t &gsdlhome) { 132 133 text_t historyfile = filename_cat(gsdlhome, "etc", "history.db"); 131 134 132 135 // open the history database … … 142 145 143 146 //deletes only the selected records 144 bool delete_history_info(const text_t &userid, const text_t &deletemode, const text_t &selection) { 145 146 text_t historyfile = filename_cat(GSDL_GSDLHOME, "etc", "history.db"); 147 bool delete_history_info (const text_t &userid, const text_t &deletemode, 148 const text_t &selection, const text_t &gsdlhome) { 149 150 text_t historyfile = filename_cat(gsdlhome, "etc", "history.db"); 147 151 bool result; 148 152 // open the history database … … 305 309 // replaces a reference to a previous query with the search 306 310 // string from that query 307 bool combine_query(text_t &userid, text_t &query )311 bool combine_query(text_t &userid, text_t &query, const text_t &gsdlhome) 308 312 { 309 313 text_t::iterator begin = query.begin(); … … 314 318 315 319 text_t queryresult = ""; 316 text_t historyfile = filename_cat( GSDL_GSDLHOME, "etc", "history.db");320 text_t historyfile = filename_cat(gsdlhome, "etc", "history.db"); 317 321 text_t historyresult; 318 322 // open the history database -
trunk/gsdl/src/recpt/historydb.h
r939 r963 51 51 // returns true on success (in which case historyinfo will contain 52 52 // the information for this history) 53 bool get_history_info ( const text_t &userid, text_tarray &historyinfo, ostream &logout); 53 bool get_history_info (const text_t &userid, text_tarray &historyinfo, 54 const text_t &gsdlhome, ostream &logout); 54 55 55 56 // returns true on success 56 bool set_history_info (const text_t &userid, const text_t &historyinfo); 57 bool set_history_info (const text_t &userid, const text_t &historyinfo, 58 const text_t &gsdlhome); 57 59 58 bool delete_all_history_info (const text_t &userid );60 bool delete_all_history_info (const text_t &userid, const text_t &gsdlhome); 59 61 60 62 // deletes only the entries specified 61 63 bool delete_history_info(const text_t &userid, const text_t &deletemode, 62 const text_t &selection );64 const text_t &selection, const text_t &gsdlhome); 63 65 64 66 // takes a text_t with x-y, and retrieves the x and y params … … 72 74 // second version looks it up inthe records map (used in 73 75 // delete history -are doing a lotof #x replacing at once. 74 bool combine_query(text_t &userid, text_t &query );76 bool combine_query(text_t &userid, text_t &query, const text_t &gsdlhome); 75 77 bool combine_query(text_t &userid, HistRecordmap &records); 76 78 -
trunk/gsdl/src/recpt/librarymain.cpp
r937 r963 28 28 /* 29 29 $Log$ 30 Revision 1.23 2000/02/21 21:59:37 sjboddie 31 gsdlhome now comes from gsdlsite.cfg 32 30 33 Revision 1.22 2000/02/17 02:35:48 sjboddie 31 34 tidied up a bit … … 138 141 #include "htmlbrowserclass.h" 139 142 140 #include " gsdlhome.h"143 #include "recptconfig.h" 141 144 142 145 int main () { 143 146 receptionist recpt; 144 147 nullproto nproto; 145 146 148 text_tarray collections; 147 if (!read_dir (GSDL_GSDLHOME "/collect", collections)) exit (1); 149 150 // get gsdlhome (if we fail the error will be picked up later -- in 151 // cgiwrapper) 152 text_t gsdlhome; 153 if (site_cfg_read (gsdlhome)) { 154 text_t collectdir = filename_cat (gsdlhome, "collect"); 155 if (!read_dir (collectdir, collections)) exit (1); 156 } 148 157 149 158 text_tarray::const_iterator thiscol = collections.begin(); 150 159 text_tarray::const_iterator endcol = collections.end(); 151 160 152 161 while (thiscol != endcol) { 153 162 154 163 // ignore the modelcol 155 if (*thiscol == "modelcol") { 156 thiscol ++; 157 continue; 158 } 159 164 if (*thiscol == "modelcol") {thiscol ++; continue;} 165 160 166 // this memory is created but never destroyed 161 167 // we're also not doing any error checking to make sure we didn't … … 168 174 filterclass *filter = new filterclass (); 169 175 cserver->add_filter (filter); 170 176 171 177 // add a browse filter 172 178 browsefilterclass *browsefilter = new browsefilterclass(); … … 179 185 queryfilter->set_mgsearchptr (mgsearch); 180 186 cserver->add_filter (queryfilter); 181 187 182 188 // add a mg and gdbm source 183 189 mggdbmsourceclass *mggdbmsource = new mggdbmsourceclass (); … … 196 202 // add the protocol to the receptionist 197 203 recpt.add_protocol (&nproto); 198 204 199 205 // add other converters 200 206 utf8inconvertclass utf8inconvert; … … 202 208 recpt.add_converter ("u", &utf8inconvert, &utf8outconvert); 203 209 204 mapinconvertclass gbinconvert; 205 gbinconvert.setmapfile (GSDL_GSDLHOME, "gbku", 0x25a1); 206 mapoutconvertclass gboutconvert; 207 gboutconvert.setmapfile (GSDL_GSDLHOME, "ugbk", 0xa1f5); 208 recpt.add_converter ("g", &gbinconvert, &gboutconvert); 210 if (!gsdlhome.empty()) { 211 mapinconvertclass gbinconvert; 212 gbinconvert.setmapfile (gsdlhome, "gbku", 0x25a1); 213 mapoutconvertclass gboutconvert; 214 gboutconvert.setmapfile (gsdlhome, "ugbk", 0xa1f5); 215 recpt.add_converter ("g", &gbinconvert, &gboutconvert); 216 } 209 217 210 218 // the list of actions. Note: these actions will become invalid -
trunk/gsdl/src/recpt/recptconfig.cpp
r533 r963 28 28 /* 29 29 $Log$ 30 Revision 1.6 2000/02/21 21:55:33 sjboddie 31 gsdlhome now comes from gsdlsite.cfg 32 30 33 Revision 1.5 1999/09/07 04:56:59 sjboddie 31 34 added GPL notice … … 67 70 68 71 // reads site configuration file returning true on success 69 bool site_cfg_read (receptionist &recpt, const text_t &gsdlhome, 70 const text_t &collection, int &maxrequests) { 72 // also sets gsdlhome and maxrequests 73 // gsdlsite.cfg should be in same directory as library executable 74 bool site_cfg_read (receptionist &recpt, text_t &gsdlhome, int &maxrequests) { 71 75 72 maxrequests = 10000; // a reasonable default76 gsdlhome.clear(); 73 77 74 // Look for site.cfg in GSDLHOME/collect/collection-name/etc directory 75 // (if this is for a particular collection), and then GSDLHOME/etc. 76 text_t filename; 77 if (!collection.empty()) { 78 filename = filename_cat (gsdlhome, "collect"); 79 filename = filename_cat (filename, collection); 80 filename = filename_cat (filename, "etc"); 81 filename = filename_cat (filename, "site.cfg"); 82 if (!file_exists (filename)) filename.clear(); 83 } 84 if (filename.empty()) { 85 filename = filename_cat (gsdlhome, "etc"); 86 filename = filename_cat (filename, "site.cfg"); 87 if (!file_exists (filename)) return false; 88 } 89 90 // read in the site configuration file 78 // Look for gsdlsite.cfg in same directory that executable is in. 91 79 text_tarray cfgline; 92 80 text_t key; 93 char *cstr = filename.getcstr(); 94 ifstream confin (cstr); 95 delete cstr; 81 ifstream confin ("gsdlsite.cfg"); 96 82 97 83 if (confin) { … … 100 86 key = cfgline[0]; 101 87 cfgline.erase(cfgline.begin()); 102 88 103 89 if (key == "maxrequests") { 104 90 maxrequests = cfgline[0].getint(); 105 91 if (maxrequests < 1) maxrequests = 1; 106 92 } 93 94 if (key == "gsdlhome") 95 gsdlhome = cfgline[0]; 107 96 108 97 // configure the receptionist … … 116 105 } 117 106 107 // this version just grabs gsdlhome, returns false if it can't find it 108 bool site_cfg_read (text_t &gsdlhome) { 109 110 gsdlhome.clear(); 111 112 // Look for gsdlsite.cfg in same directory that executable is in. 113 text_tarray cfgline; 114 text_t key; 115 ifstream confin ("gsdlsite.cfg"); 116 117 if (confin) { 118 while (read_cfg_line(confin, cfgline) >= 0) { 119 if (cfgline.size () >= 2) { 120 if (cfgline[0] == "gsdlhome") { 121 gsdlhome = cfgline[1]; 122 return true; 123 } 124 } 125 } 126 confin.close (); 127 } 128 return false; 129 } 118 130 119 131 // main_cfg_read reads both main.cfg and collect.cfg. It attempts -
trunk/gsdl/src/recpt/recptconfig.h
r533 r963 37 37 38 38 // reads site configuration file returning true on success 39 bool site_cfg_read (receptionist &recpt, const text_t &gsdlhome,40 const text_t &collection, int &maxrequests);39 bool site_cfg_read (receptionist &recpt, text_t &gsdlhome, int &maxrequests); 40 bool site_cfg_read (text_t &gsdlhome); 41 41 42 42 // main_cfg_read reads either collect.cfg or main.cfg and returning … … 44 44 // collection is specified and then it tries to read in main.cfg 45 45 bool main_cfg_read (receptionist &recpt, const text_t &gsdlhome, 46 46 const text_t &collection); 47 47 48 48
Note:
See TracChangeset
for help on using the changeset viewer.