mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-07-21 01:50:30 +00:00
Fix bugs and make code tinier
- Fixed bug where stdio eof wasn't being sticky - Fixed bug where fseeko() wasn't clearing eof state - Removed assert() usage from libc favoring _unassert() / _npassert()
This commit is contained in:
parent
9b7c8db846
commit
d5910e2673
115 changed files with 510 additions and 290 deletions
|
@ -34,10 +34,7 @@ const char *(DescribeOpenFlags)(char buf[128], int x) {
|
|||
struct DescribeFlags d[N];
|
||||
// TODO(jart): unify DescribeFlags and MagnumStr data structures
|
||||
for (n = 0; kOpenFlags[n].x != MAGNUM_TERMINATOR; ++n) {
|
||||
if (n == N) {
|
||||
assert(!"too many open flags");
|
||||
break;
|
||||
}
|
||||
if (n == N) notpossible;
|
||||
}
|
||||
for (i = 0; i < n; ++i) {
|
||||
d[i].flag = MAGNUM_NUMBER(kOpenFlags, i);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue