Changeset 467
- Timestamp:
- Apr 25, 2014, 9:51:59 PM (11 years ago)
- Location:
- trunk/zoo-project
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/zoo-project/zoo-kernel/makefile.vc
r465 r467 8 8 !INCLUDE nmake.opt 9 9 10 all: zoo_loader.cgi 10 all: zoo_loader.cgi zcfg2yaml 11 11 12 12 version.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 17 15 18 16 main_conf_read.tab.c: main_conf_read.y service.h … … 39 37 lex.sr.obj: lex.sr.c service.h 40 38 $(CPP) $(CFLAGS) /c lex.sr.c 39 40 zcfg2yaml.obj: zcfg2yaml.c 41 $(CPP) $(CFLAGS) /c zcfg2yaml.c 41 42 42 43 service_internal.obj: service_internal.c … … 70 71 $(CPP) /EHsc /c $(CFLAGS) ..\..\thirds\dirent-win32\dirent.c 71 72 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.obj73 zoo_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 73 74 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 76 zcfg2yaml.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) 74 78 75 79 clean: -
trunk/zoo-project/zoo-kernel/service_internal.c
r465 r467 35 35 #endif 36 36 37 int readServiceFile(maps* conf, char* file,service** service,char *name){38 int t=getServiceFromFile(conf,file,service);39 #ifdef YAML40 if(t<0){41 t=getServiceFromYAML(conf,file,service,name);42 }43 #endif44 return t;45 }46 47 37 void printHeaders(maps* m){ 48 38 maps *_tmp=getMaps(m,"headers"); … … 133 123 134 124 char* getStatus(int pid){ 135 char lpszBuf[SHMEMSIZE];125 char *lpszBuf=(char*) malloc(SHMEMSIZE*sizeof(char)); 136 126 int i=0; 137 127 LPWSTR lpszTmp=NULL; -
trunk/zoo-project/zoo-kernel/service_internal.h
r465 r467 42 42 #include <sys/shm.h> 43 43 #else 44 #include "cgic.h" 44 45 #include <direct.h> 45 46 #endif … … 65 66 #include "ulinet.h" 66 67 67 extern int getServiceFromFile(maps*,const char*,service**);68 68 extern int conf_read(const char*,maps*); 69 69 -
trunk/zoo-project/zoo-kernel/zcfg2yaml.c
r465 r467 26 26 #include "service_internal.h" 27 27 28 extern int getServiceFromFile(maps*,const char*,service**); 29 28 30 int main(int argc, char** argv){ 29 31 service* s1=NULL; … … 35 37 return errorException(m, _("Unable to allocate memory."),"InternalError",NULL); 36 38 } 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); 39 42 return 0; 40 43 } -
trunk/zoo-project/zoo-kernel/zoo_service_loader.c
r466 r467 95 95 #ifndef USE_MS 96 96 { 97 char *x= _zStrdup(a);98 char *y= _zStrdup(b);97 char *x=zStrdup(a); 98 char *y=zStrdup(b); 99 99 100 100 x=_strlwr(x); … … 115 115 #define __(String) dgettext ("zoo-service",String) 116 116 117 extern int getServiceFromFile(maps*,const char*,service**); 118 119 int 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 } 117 128 118 129 void translateChar(char* str,char toReplace,char toReplaceBy){ -
trunk/zoo-project/zoo-services/utils/status/service.c
r440 r467 121 121 setMapInMaps(outputs,"Result","value",(char*)xmlbuff); 122 122 xmlFree(xmlbuff); 123 free(tmpStr); 123 124 free(tmpStr1); 124 125 free(tmpStr0);
Note: See TracChangeset
for help on using the changeset viewer.