Changeset d2cc7e1 in mainline for uspace/lib/libc/generic/io/stream.c
- Timestamp:
- 2009-03-21T11:26:31Z (16 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 0a5116db
- Parents:
- 5b8c75a
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/libc/generic/io/stream.c
r5b8c75a rd2cc7e1 81 81 { 82 82 int cons_phone = console_phone_get(false); 83 int left, rc; 83 84 84 85 if (cons_phone >= 0) { 85 86 int i; 86 87 87 for (i = 0; i < count; i++) 88 console_putchar(((const char *) buf)[i]); 88 left = count; 89 while (left > 0) { 90 rc = console_write(buf, left); 91 if (rc < 0) 92 break; 93 buf += rc; 94 left -= rc; 95 } 89 96 90 97 return count; 91 98 } else 92 99 return __SYSCALL3(SYS_KLOG, 1, (sysarg_t) buf, count); 100 } 101 102 int flush_stdout(void) 103 { 104 console_flush(); 105 return 0; 93 106 } 94 107
Note:
See TracChangeset
for help on using the changeset viewer.