#define americano 0 #define europeo 1 #define lmax 200 #define posin 18 #define ladat 200 #define estac 18+posin #define linea 17+posin #define durac 28+posin #define hor 8+posin #define fech 0+posin #define tranf 68+posin #define numero 36+posin //#define numero 42+posin #define ccost 0 #define proye 69+posin #define cuenta 0 #define pulsos 70+posin #define ruta 0 #define prinum 0 #define ring 23+posin #define antran 0 // anexo transferido #define larnum 23 #define fofech europeo extern char rgua[]; void in_central() { rgua[0]='\0'; } void fi_central() { } void DatCentral(char *buf, char *tel, int vestac, int vlinea,int vdurac,int vhor, int vfech, int vtranf, int vnumero, int vccost,int vproye, int vcuenta, int vpulsos, int vruta, int vprinum, int vring, int vantran, int vfofech) { int k,j,i=strlen(buf); char aux,vtip ; aux = 0; if (i> vtranf && buf[fech+2]=='.' && buf[fech+5]=='.' && buf[hor+2]==':'&& buf[durac+2]==':' && buf[durac+5]==':') { k=0 ; if (buf[vtranf]=='2' || buf[vtranf]=='6') vtip = 'O'; else vtip = 'I' ; for(j=0;j<5; j++) { if(isdigit(buf[estac+j])) tel[k++]=buf[vestac+j]; } tel[k++] = ' ' ; tel[k++] = buf[vlinea] ; tel[k++] = ' ' ; tel[k++] = buf[vdurac+0] ; tel[k++] = buf[vdurac+1] ; tel[k++] = buf[vdurac+2] ; tel[k++] = buf[vdurac+3] ; tel[k++] = buf[vdurac+4] ; tel[k++] = ':'; tel[k++] = buf[vdurac+6]; tel[k++] = buf[vdurac+7]; tel[k++] = ' '; tel[k++] = buf[vhor+0] ; tel[k++] = buf[vhor+1] ; tel[k++] = buf[vhor+2] ; tel[k++] = buf[vhor+3] ; tel[k++] = buf[vhor+4] ; tel[k++] = ' ' ; if (vfofech==europeo) { tel[k++] = buf[vfech+3] ; tel[k++] = buf[vfech+4] ; tel[k++] = '/' ; tel[k++] = buf[vfech]; tel[k++] = buf[vfech+1] ; tel[k++] = '/' ; } else { tel[k++] = buf[vfech+0] ; tel[k++] = buf[vfech+1] ; tel[k++] = '/' ; tel[k++] = buf[vfech+3] ; tel[k++] = buf[vfech+4] ; tel[k++] = '/' ; } tel[k++] = buf[6] ; tel[k++] = buf[7] ; tel[k++] = ' ' ; tel[k++] = vtip ; tel[k++] = ' ' ; if (vtip =='O' || (vtip=='I' && isdigit(buf[vnumero]))) { for (j = 0; buf[vnumero+j]!=' ';j++) { if(isdigit(buf[vnumero+j])) tel[k++] = buf[vnumero+j]; } } else tel[k++] = '*' ; tel[k++] = ' ' ; tel[k++] = '*' ; // Código de Cuenta tel[k++] = ' ' ; if isdigit(buf[vproye]) { for (j = 0; buf[vproye+j]!=' ' && j