Changeset 1864

Show
Ignore:
Timestamp:
26.01.2001 10:29:32 (19 years ago)
Author:
sjboddie
Message:

Fixed a couple of minor things to get it compiling on windows again

Location:
trunk/gsdl
Files:
3 modified

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/lib/cnfgator.h

    r1860 r1864  
    1 #include <vector.h> 
     1#if defined(GSDL_USE_OBJECTSPACE) 
     2#  include <ospace/std/vector> 
     3#  include <ospace/std/vector> 
     4#elif defined(GSDL_USE_IOS_H) 
     5#  include <vector.h> 
     6#else 
     7#  include <vector> 
     8#endif 
    29 
    310#include "cfgread.h" 
  • trunk/gsdl/lib/fileutil.cpp

    r1837 r1864  
    346346// For current needs it's fine though. 
    347347// -- Pass a linelength of 0 to use the default linelength (256 chars). 
     348// -- The maximum value of linelength is MAXLINELENGTH 
    348349text_t file_tail (const text_t &filename, int numlines, int linelength) { 
    349350 
     351#define MAXLINELENGTH 2048 
     352 
    350353  if (numlines < 1) numlines = 1; 
    351   if (linelength == 0) linelength = 256; 
    352    
     354  if (linelength < 1) linelength = 256; 
     355  if (linelength > MAXLINELENGTH) linelength = MAXLINELENGTH; 
     356 
    353357  streampos numchars = linelength*numlines; 
    354358 
     
    357361 
    358362  char *filenamec = filename.getcstr(); 
    359   char linec[linelength]; 
     363  char linec[MAXLINELENGTH]; 
    360364  ifstream file_in (filenamec); 
    361365  delete filenamec; 
  • trunk/gsdl/src/recpt/cgiwrapper.cpp

    r1860 r1864  
    3030#include <stdlib.h> 
    3131#include <assert.h> 
    32 #include <iostream.h> 
    3332 
    3433#if defined(GSDL_USE_OBJECTSPACE) 
     
    282281 
    283282  outconvertclass text_t2ascii; 
    284   recptconf &configinfo = recpt.get_configinfo (); 
     283  const recptconf &configinfo = recpt.get_configinfo (); 
    285284  text_t etc_dir = filename_cat (configinfo.gsdlhome, "etc"); 
    286285 
     
    449448  int numrequests = 0; 
    450449  bool debug = false; 
    451   recptconf configinfo = recpt.get_configinfo (); 
     450  const recptconf &configinfo = recpt.get_configinfo (); 
    452451 
    453452  // find out whether this is being run as a cgi-script