Changeset 467 for trunk/zoo-project


Ignore:
Timestamp:
Apr 25, 2014, 9:51:59 PM (11 years ago)
Author:
djay
Message:

Various fixes for tickets #93, #94, #95, #95, #96.

Location:
trunk/zoo-project
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/zoo-project/zoo-kernel/makefile.vc

    r465 r467  
    88!INCLUDE nmake.opt
    99
    10 all:  zoo_loader.cgi
     10all:  zoo_loader.cgi zcfg2yaml
    1111
    1212version.h:
    13         svnversion -q -c -n . > version_0.h
    14         set /p VERS=<version_0.h
    15         rm version_0.h
    16         echo #define ZOO_VERSION "%VERS%" > version.h
     13        set VERS=`svnversion .`
     14        echo #define ZOO_VERSION "$(VERS)" > version.h
    1715
    1816main_conf_read.tab.c: main_conf_read.y service.h
     
    3937lex.sr.obj: lex.sr.c service.h
    4038        $(CPP) $(CFLAGS) /c lex.sr.c
     39
     40zcfg2yaml.obj: zcfg2yaml.c
     41        $(CPP) $(CFLAGS) /c zcfg2yaml.c
    4142
    4243service_internal.obj: service_internal.c
     
    7071        $(CPP) /EHsc /c $(CFLAGS) ..\..\thirds\dirent-win32\dirent.c
    7172
    72 zoo_loader.cgi: zoo_loader.obj zoo_service_loader.obj service_internal.obj $(PY_FILE) $(JAVA_FILE) $(MS_FILE) $(JS_FILE) $(RUBY_FILE) ulinet.obj lex.cr.obj lex.sr.obj service_conf.tab.obj main_conf_read.tab.obj dirent.obj
     73zoo_loader.cgi: version.h zoo_loader.obj zoo_service_loader.obj service_internal.obj $(PY_FILE) $(JAVA_FILE) $(MS_FILE) $(JS_FILE) $(RUBY_FILE) ulinet.obj lex.cr.obj lex.sr.obj service_conf.tab.obj main_conf_read.tab.obj dirent.obj
    7374        link zoo_loader.obj dirent.obj service_internal.obj $(PY_FILE) $(JAVA_FILE) $(MS_FILE) $(JS_FILE) $(RUBY_FILE) ulinet.obj main_conf_read.tab.obj lex.cr.obj service_conf.tab.obj lex.sr.obj  zoo_service_loader.obj /out:zoo_loader.cgi $(LDFLAGS) $(LDFLAGSCGI)
     75
     76zcfg2yaml.exe: version.h zcfg2yaml.obj zoo_service_loader.obj service_internal.obj $(PY_FILE) $(JAVA_FILE) $(MS_FILE) $(JS_FILE) $(RUBY_FILE) ulinet.obj lex.cr.obj lex.sr.obj service_conf.tab.obj main_conf_read.tab.obj dirent.obj
     77        link zcfg2yaml.obj dirent.obj service_internal.obj $(PY_FILE) $(JAVA_FILE) $(MS_FILE) $(JS_FILE) $(RUBY_FILE) ulinet.obj main_conf_read.tab.obj lex.cr.obj service_conf.tab.obj lex.sr.obj /out:zcfg2yaml.exe $(LDFLAGS) $(LDFLAGSCGI)
    7478
    7579clean:
  • trunk/zoo-project/zoo-kernel/service_internal.c

    r465 r467  
    3535#endif
    3636
    37 int readServiceFile(maps* conf, char* file,service** service,char *name){
    38   int t=getServiceFromFile(conf,file,service);
    39 #ifdef YAML
    40   if(t<0){
    41     t=getServiceFromYAML(conf,file,service,name);
    42   }
    43 #endif
    44   return t;
    45 }
    46 
    4737void printHeaders(maps* m){
    4838  maps *_tmp=getMaps(m,"headers");
     
    133123
    134124char* getStatus(int pid){
    135   char lpszBuf[SHMEMSIZE];
     125  char *lpszBuf=(char*) malloc(SHMEMSIZE*sizeof(char));
    136126  int i=0;
    137127  LPWSTR lpszTmp=NULL;
  • trunk/zoo-project/zoo-kernel/service_internal.h

    r465 r467  
    4242#include <sys/shm.h>
    4343#else
     44#include "cgic.h"
    4445#include <direct.h>
    4546#endif
     
    6566#include "ulinet.h"
    6667
    67 extern   int getServiceFromFile(maps*,const char*,service**);
    6868extern   int conf_read(const char*,maps*);
    6969
  • trunk/zoo-project/zoo-kernel/zcfg2yaml.c

    r465 r467  
    2626#include "service_internal.h"
    2727
     28extern   int getServiceFromFile(maps*,const char*,service**);
     29
    2830int main(int argc, char** argv){
    2931  service* s1=NULL;
     
    3537    return errorException(m, _("Unable to allocate memory."),"InternalError",NULL);
    3638  }
    37   readServiceFile(m,argv[1],&s1,argv[2]);
    38   dumpServiceAsYAML(s1);
     39  int t=getServiceFromFile(conf,file,service);
     40  if(t>=0)
     41    dumpServiceAsYAML(s1);
    3942  return 0;
    4043}
  • trunk/zoo-project/zoo-kernel/zoo_service_loader.c

    r466 r467  
    9595#ifndef USE_MS
    9696 {
    97   char *x=_zStrdup(a);
    98   char *y=_zStrdup(b);
     97  char *x=zStrdup(a);
     98  char *y=zStrdup(b);
    9999 
    100100  x=_strlwr(x);
     
    115115#define __(String) dgettext ("zoo-service",String)
    116116
     117extern   int getServiceFromFile(maps*,const char*,service**);
     118
     119int readServiceFile(maps* conf, char* file,service** service,char *name){
     120  int t=getServiceFromFile(conf,file,service);
     121#ifdef YAML
     122  if(t<0){
     123    t=getServiceFromYAML(conf,file,service,name);
     124  }
     125#endif
     126  return t;
     127}
    117128
    118129void translateChar(char* str,char toReplace,char toReplaceBy){
  • trunk/zoo-project/zoo-services/utils/status/service.c

    r440 r467  
    121121        setMapInMaps(outputs,"Result","value",(char*)xmlbuff);
    122122        xmlFree(xmlbuff);
     123        free(tmpStr);
    123124        free(tmpStr1);
    124125        free(tmpStr0);
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