Victor, This happens because cint can only output string of only 1024 length. ANSI C standard requests printf to output , at least , 512 characters. In this sense, cint conforms to the standard. Of course it is nicer to allow unlimited length of string which is not too difficult. For now, I modified cint to display warning message for this. I recommend doing it as follows. fprintf(fp,"@echo %d \n@echo ",i); fputs(buffer,fp); fputc('\n',fp); Valery requested a list of cint limit numbers. I hope following list helps. Length of string for printf 1024 G__LONGLINE Number of function arguments 40 G__MAXFUNCPARA Maximum number of input files 500 G__MAXFILE Maximum filename length 256 G__MAXFILENAME Maximum array dimention 10 G__MAXVARDIM Maximum number of base classes 30 G__MAXBASE Maximum depth of class and namespace scope nesting 20 G__TAGNEST Maximum number of class/struct/enum/namespace/union 1600 G__MAXSTRUCT Maximum number of typedef 1000 G__MAXTYPEDEF Maximum length of C/C++ statement 1024 G__LONGLINE Maximum number of scanf arguments 12 Masaharu Goto > hello Rooter, > The macro below crashes root (under Windows and some UNIX) after i=1023 > Any idea ? >{ > Int_t i = 0; > Char_t buffer[5000]; > FILE *fp = fopen("test.bat","w"); > strcpy(buffer,"."); > for (i=0;i<4096;i++) { > strcat(buffer,"."); > fprintf(fp,"@echo %d \n@echo %s\n",i,buffer); > } >} > > Valery & Victor
This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:34:33 MET