Back to home page

DOS ain't dead

Forum index page

Log in | Register

Back to the forum
Board view  Mix view

22nd IOCCC winners (Announce)

posted by RayeR Homepage, CZ, 25.01.2014, 15:30

I looked into the source and found a place where it probably do all outputs on textmode screen (line 650):

NEXT_OPCODE_SUBFUNCTION // PUTCHAR_AL
write(1, regs8, 1)

There's no any putchar, putc, pritnf, frprint in the code. According to libC reference write() is common function to write in file, args are: int file descriptor, void pointer to data, lenght). The question is where they sucked out of thumb the file descriptor value 1. There's no open() call to get the file no. So it would be probably some standard file like STDOUT but for some reason it doesn't work in DJGPP. Maybe there's a different constant or I need call open() first...?
Here's nothing about magic constants http://www.delorie.com/djgpp/doc/libc/libc_866.html

---
DOS gives me freedom to unlimited HW access.

 

Complete thread:

Back to the forum
Board view  Mix view
22777 Postings in 2122 Threads, 402 registered users (0 online)
DOS ain't dead | Admin contact
RSS Feed
powered by my little forum