VERBATIM/b338c: #include <stdlib.h> int system(com) char *com; |
VERBATIM/b338d: #include <stdio.h> FILE *popen(command, type) char *command, *type; |
VERBATIM/b338a: FILE *fp; char datum[10], zeit[10], bez[50]; ... fpr=popen("sort -o Termine","w") if(fpr == NULL) { /* Fehlerbehandlung */ } fprintf(fpr,"%s %s %s ",datum,zeit,bez); pclose(fp); |
VERBATIM/b338b: #define DIR "/haushalt/" .... FILE *fp; char ucom[100], jahrgang[5]; .... strcpy(ucom,"cat "); strcat(ucom,DIR); strcat(ucom,jahrgang); strcat(ucom,"/*/*/rechnungen | cut -f3-5 | sort "); if((fp=popen(ucom,"r")) == NULL) { ...... } while((fread(&rech,sizeof(struct rech),1,fp)) != 0) { .... } pclose(fp); |