Message-Id: <200310150551.h9F5p7Sq013531@delorie.com> Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Date: Wed, 15 Oct 2003 03:27:55 -0300 To: cygwin AT cygwin DOT com From: "Moises D. Deangelo" Cc: X-Originating-IP: [200.226.133.253]200.226.228.199 X-user: lewris AT ig DOT com DOT br MIME-Version: 1.0 Content-type: text/plain Subject: Re: system() refuses to work!!! HELP It did not work. Will it be that I found a bug??? How much luck I have.. :-) It follows the source. that program does not do anything of important! It is alone a test. what we most can do? I changed the command for "DIR" who list the directories of the windows just to facilitate the comprehension and so that it to do not are necessary to do an upload of sound.exe. Try, with that program execute some other command! Here, already tried of everything, and anything (not) worked. ************************************************* #include #include #include main() { int a,b,c,d,e,f,g,h,j; FILE *stream; printf("Programa Gerador de Resultados para Teste:"); printf("\n\nEntre com as Faixas"); printf("\nNúmero a ser comparado: ");scanf("%d",&c); printf("\n....................De: ");scanf("%d",&a); printf("\n.....................A: ");scanf("%d",&b); d = c; f = a; g = b; j = 1; while(g <= c){ e = f * g; h = d - e; if((stream = fopen("dtr1.txt", "at")) != NULL){ fprintf(stream,"\n %d * %d = %d -r = %d",f,g,e,h); } fflush(stdout); fclose(stream); if(j >= c){ f = a; j = 0; g++; printf("\nF: %d\tG %d:",f,g); fflush(stdout); } f++; j++; } if((system("dir")) == 0){ printf("\n\nComando executado com sucesso"); } else{ printf("\n\ncomando falhou"); } } *********************************************** Em 15 Oct 2003, cygwin AT cygwin DOT com escreveu: >On Wed, Oct 15, 2003 at 01:10:08AM -0300, Moises D. Deangelo wrote: >>When entering with the command ls -l /bin/sh.exe, the appeared following: >> >>-rwxr-x---+ 1 Diego Usu?rios 83456 Aug 11 10:45 /bin/sh.exe > >Ok. The next question is if "sound.exe" is in your path. Does something >like: > >system("/cygdrive/c/dir/sound.exe") > >work? > >/cygdrive/c/dir would be cygwin's way of typing c:/dir > >dir would be the place where sound.exe lives. > >-- >Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple >Problem reports: http://cygwin.com/problems.html >Documentation: http://cygwin.com/docs.html >FAQ: http://cygwin.com/faq/ > >---------- _________________________________________________________ Voce quer um iGMail protegido contra vírus e spams? Clique aqui: http://www.igmailseguro.ig.com.br Ofertas imperdíveis! Link: http://www.americanas.com.br/ig/ -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/