Changeset 214 for trunk


Ignore:
Timestamp:
May 25, 2011, 2:54:50 PM (14 years ago)
Author:
djay
Message:

Small fix for remote input data download checking for protocol (supporting http anf ftp). Add the tabulation character support in ZCFG to avoid requirement of duplicate stdout, which is still in place for characters not supported in the ZCFG files.

Location:
trunk/zoo-kernel
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/zoo-kernel/service_conf.l

    r100 r214  
    4141
    4242attname [a-zA-Z0-9_\-]+
    43 attvalue1       [\^\*\+,;@a-zA-Z0-9_\-::.:" "\"\'/\\\(\)]+
     43attvalue1       [\^\*\+,;@a-zA-Z0-9_\-::.:" "\"\'/\\\(\)\t\|]+
    4444
    4545attvalue                \"[^"]*\"|\'[^']*\'\(\)
    4646
    47 whitespace                      [ ]{0,}
    48 whitesp                      [ ]
     47whitespace                      [\t]{0,}|[ ]{0,}
     48whitesp                      [\t]|[ ]
    4949newline                 [\r\n]|[\n]
    5050newlines                 [\r\n]{1,}|[\n]{1,}
  • trunk/zoo-kernel/zoo_service_loader.c

    r127 r214  
    511511      n = printGetCapabilitiesHeader(doc,"",m);
    512512    /**
    513      * Strange, here we need to close stdout to ensure that no uneeded
    514      * char will be printed (parser issue ?)
     513     * Here we need to close stdout to ensure that not supported chars
     514     * has been found in the zcfg and then printed on stdout
    515515     */
    516516    int saved_stdout = dup(fileno(stdout));
     
    921921            addToMap(tmpmaps->content,tmpn1,tmpv1+1);
    922922          else{
     923            if(strncasecmp(tmpv1+1,"http://",7)!=0 &&
     924               strncasecmp(tmpv1+1,"ftp://",6)!=0){
     925              char emsg[1024];
     926              sprintf(emsg,_("Unable to find a valid protocol to download the remote file %s"),tmpv1+1);
     927              errorException(m,emsg,"InternalError");
     928              freeMaps(&m);
     929              free(m);
     930              free(REQUEST);
     931              free(SERVICE_URL);
     932              InternetCloseHandle(hInternet);
     933              freeService(&s1);
     934              free(s1);
     935              return 0;
     936            }
    923937#ifdef DEBUG
    924938            fprintf(stderr,"REQUIRE TO DOWNLOAD A FILE FROM A SERVER : url(%s)\n",tmpv1+1);
Note: See TracChangeset for help on using the changeset viewer.

Search

Context Navigation

ZOO Sponsors

http://www.zoo-project.org/trac/chrome/site/img/geolabs-logo.pnghttp://www.zoo-project.org/trac/chrome/site/img/neogeo-logo.png http://www.zoo-project.org/trac/chrome/site/img/apptech-logo.png http://www.zoo-project.org/trac/chrome/site/img/3liz-logo.png http://www.zoo-project.org/trac/chrome/site/img/gateway-logo.png

Become a sponsor !

Knowledge partners

http://www.zoo-project.org/trac/chrome/site/img/ocu-logo.png http://www.zoo-project.org/trac/chrome/site/img/gucas-logo.png http://www.zoo-project.org/trac/chrome/site/img/polimi-logo.png http://www.zoo-project.org/trac/chrome/site/img/fem-logo.png http://www.zoo-project.org/trac/chrome/site/img/supsi-logo.png http://www.zoo-project.org/trac/chrome/site/img/cumtb-logo.png

Become a knowledge partner

Related links

http://zoo-project.org/img/ogclogo.png http://zoo-project.org/img/osgeologo.png