Formatted
This commit is contained in:
parent
5ef6a7a98a
commit
5917f409c5
|
@ -263,12 +263,10 @@ main(int argc, char **argv)
|
||||||
read(fds[1].fd, expirations, 8); /* Indicate we handled the timer */
|
read(fds[1].fd, expirations, 8); /* Indicate we handled the timer */
|
||||||
uxn_eval(&u, GETVEC(&u.dev[0x20])); /* Call the vector once, even if the timer fired multiple times */
|
uxn_eval(&u, GETVEC(&u.dev[0x20])); /* Call the vector once, even if the timer fired multiple times */
|
||||||
}
|
}
|
||||||
if ((fds[2].revents & POLLIN)!=0)
|
if((fds[2].revents & POLLIN) != 0) {
|
||||||
{
|
|
||||||
n = read(fds[2].fd, coninp, CONINBUFSIZE - 1);
|
n = read(fds[2].fd, coninp, CONINBUFSIZE - 1);
|
||||||
coninp[n] = 0;
|
coninp[n] = 0;
|
||||||
for (i=0;i<n;i++)
|
for(i = 0; i < n; i++) {
|
||||||
{
|
|
||||||
console_input(&u, coninp[i]);
|
console_input(&u, coninp[i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -37,8 +37,8 @@ console_input(Uxn *u, char c)
|
||||||
static void
|
static void
|
||||||
console_deo(Uint8 *d, Uint8 port)
|
console_deo(Uint8 *d, Uint8 port)
|
||||||
{
|
{
|
||||||
FILE *fd = port == 0x8 ? stdout : port == 0x9 ? stderr
|
FILE *fd = port == 0x8 ? stdout : port == 0x9 ? stderr :
|
||||||
: 0;
|
0;
|
||||||
if(fd) {
|
if(fd) {
|
||||||
fputc(d[port], fd);
|
fputc(d[port], fd);
|
||||||
fflush(fd);
|
fflush(fd);
|
||||||
|
|
Loading…
Reference in New Issue