From: "Tim 'Zastai' Van Holder" Newsgroups: comp.os.msdos.djgpp Subject: FSEXT trouble (can they be bypassed) Lines: 32 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.50.4133.2400 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 Message-ID: Date: Sun, 20 Aug 2000 20:49:49 GMT NNTP-Posting-Host: 213.224.94.80 X-Trace: afrodite.telenet-ops.be 966804589 213.224.94.80 (Sun, 20 Aug 2000 22:49:49 MET DST) NNTP-Posting-Date: Sun, 20 Aug 2000 22:49:49 MET DST Organization: Pandora - Met vlotte tred op Internet To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com I've been working on porting tf (a MUD client); mostly as a way of testing libsocket some more. Aside from the networking, there was also the problem of the interface. Luckily, tf supports hardcoding a terminal type (including ansi), and I remembered Eli had added a FSEXT function for ANSI coloring for ls. I expanded on that code, so that it now offers a fairly complete set of ANSI terminal sequences and plugged it in - but to my surprise, it didn't work for long. Any test strings output at the start of the program were handled correctly, but at some point, the fsext function seems to get bypassed - it is no longer called. Even when I put the following lines in the source code: // Normally this is __attribute__((constructor)), but for testing it // was made a normal function djgpp_ansi_startup (); printf ("\033[L\033[36mTest\033[1m\n" ); fprintf (stdout, "\033[L\033[36mTest\033[1m\n" ); write (STDOUT_FILENO, "\033[L\033[36mTest\033[1m\n", 17 ); write (1, "\033[L\033[36mTest\033[1m\n", 17 ); it won't get called. The problem seems to be that the program also uses termios calls, so __write will just call __libc_termios_write and never use the fsext function. Is this how it's supposed to be? And, if so, how do I get around it? IE how do I prevent the termios hooks from being used (if that's at all possible without breaking the program)? -- Hi, I'm a signature virus. plz set me as your signature and help me spread :)