Ignore:
Timestamp:
2005-02-18T17:06:41+13:00 (19 years ago)
Author:
mdewsnip
Message:

Added #ifdefs for slightly different popen and pclose on Windows.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/src/colservr/lucenesearch.cpp

    r9089 r9115  
    120120  cmd += indexname + (text_t)" \"" + to_utf8(queryparams.querystring) + (text_t)"\"";
    121121
    122  
    123   FILE *PIN = popen(cmd.getcstr(),"r");
     122#ifdef __WIN32__
     123  FILE *PIN = _popen(cmd.getcstr(), "r");
     124#else
     125  FILE *PIN = popen(cmd.getcstr(), "r");
     126#endif
    124127  if (PIN==NULL) {
    125128    cerr << "Error: unable to open pipe to " << cmd << endl;
     
    137140  expat_resultset(xml_text,queryresult);
    138141
     142#ifdef __WIN32__
     143  _pclose(PIN);
     144#else
    139145  pclose(PIN);
     146#endif
    140147
    141148  return true;
Note: See TracChangeset for help on using the changeset viewer.