- versioning in macos

- fixes to input/output to improve interaction with eclipse console.
-
This commit is contained in:
Vítor Santos Costa
2014-02-20 10:38:18 +00:00
parent 42ec115e75
commit f264859483
9 changed files with 50 additions and 22 deletions

View File

@@ -2662,7 +2662,6 @@ Swrite_file(void *handle, char *buf, size_t size)
#else
bytes = write((int)h, buf, size);
#endif
if ( bytes == -1 && errno == EINTR )
{ if ( PL_handle_signals() < 0 )
{ errno = EPLEXCEPTION;
@@ -3541,8 +3540,15 @@ SinitStreams(void)
if ( !isatty(i) && s->functions == &Sttyfunctions )
{ s->flags &= ~SIO_ISATTY;
s->functions = &Sfilefunctions; /* Check for pipe? */
s->functions = &Sfilefunctions; /* Check for pipe? */
#if HAVE_SETLINEBUF
/* make sure wwe buffer on new line for ttys, eg eclipse console */
} else if (i == 1) {
setlinebuf( stdout );
#endif
}
if ( s > 0)
s->newline = SIO_NL_DOS;
if ( s->encoding == ENC_ISO_LATIN_1 )
s->encoding = enc;
#ifdef O_PLMT