Doing some research in int21.c shows that many functions that rely on CFLAG dont set it when they are in error state.
IMHO many DOS programs are already broken today since these functions appear to be successfull at every moment.
For example : INT21_FileDateTime (handler for function 0x57, file attributes)
-----Message d'origine----- De : Jukka Heinonen [mailto:jhei@iki.fi] Envoyé : lundi 18 août 2003 20:14 À : wine-devel@winehq.com Objet : Re: Int21 : Dont reset systematically CFLAG
Sylvain Petreolle wrote:
Dont reset systematically CFLAG when calling the int 21 handler. Some functions dont change it.
This patch must not be applied because it is highly likely that it will break almost all DOS programs.
Fix itself is correct but before this patch can be applied it must be made sure that all functions that are supposed to reset CFLAG really reset it.
On Fri, Aug 22, PETREOLLE Sylvain wrote:
Doing some research in int21.c shows that many functions that rely on CFLAG dont set it when they are in error state.
IMHO many DOS programs are already broken today since these functions appear to be successfull at every moment.
For example : INT21_FileDateTime (handler for function 0x57, file attributes)
Yes, it is highly likely that there are lots of small bugs in DOS interrupt handling. If you want to work on fixing those bugs, feel free to do so. However, do not submit patches that break those interrupt subfunctions that work correctly now, even if the reason they work is due to some broken workaround.
What I would suggest is: - Submit one or more patches that make each winedos/int21.c subfunction (even those that call msdos/int21.c) that is supposed to modify CFLAG modify the flag explicitly. It is fine to make those subfunctions begin with RESET_CFLAG and FIXME comment about needing to fix/verify CFLAG handling. - After all subfunctions have been reviewed, submit a patch that removes the global RESET_CFLAG.
As you can see, the amount of work you need to do does not change and you don't need to spend lots of time hunting down regressions because you don't break those programs that happen to work due to global RESET_CFLAG. Please, more patches, less talk.