Re: [Freedos-kernel] [patch] #1758 - fix incorrect AskSingleLine function

2004-06-15 Thread Bernd Blaauw
Arkady V.Belousov schreef:
- 123? present and statement not from selected menu? Skip.
- ! present? Don't skip.
- ? present or single step? Ask.
Your proposal changes behavior: now it will look so:
- 123? present and statement not from selected menu? Skip.
- ? present? Ask.
- single step and not ! present? Ask.
I wanted
0123?!ECHO?=DUMMY.SYS
also to be asked (because it contains ?= part)
in current FreeDOS kernel, the ?= part is ignored because ! is 
present. cases 4 and 8 go wrong here (auto-executed..)

echo=1// only ask when F8
echo?=2   // always ask
!echo=3   // should never ask
!echo?=4  // should always ask, even if F8
012?echo=5// only ask when F8 (and ofcourse menu 1, 2,or 3 selected)
012?echo?=6   // always ask
012?!echo=7   // never ask
012?!echo?=8  // should always ask, even if F8
ANY ?= should raise the ASK-question, even if ! is present.
Eric optimized the function a bit :)

Well... I hardly rework config.c and fix many bugs (most of them are not
check input validness - for example, break=offk accepted as on). Also I
add above your changes. If you wish/can/may, I send you my config.c for
testing.
I'll gladly receive your config.c
please send entire file, not a patch.
(I haven't learned using DIFF/PATCH yet, but learned compiling a bit)
Bernd
---
This SF.Net email is sponsored by The 2004 JavaOne(SM) Conference
Learn from the experts at JavaOne(SM), Sun's Worldwide Java Developer
Conference, June 28 - July 1 at the Moscone Center in San Francisco, CA
REGISTER AND SAVE! http://java.sun.com/javaone/sf Priority Code NWMGYKND
___
Freedos-kernel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freedos-kernel


Re: [Freedos-kernel] [patch] #1758 - fix incorrect AskSingleLine function

2004-06-14 Thread Arkady V.Belousov
Hi!

13--2004 19:39 [EMAIL PROTECTED] (Bernd Blaauw) wrote to
[EMAIL PROTECTED]:

BB Eric and I have been working a few hours on a patch to correct the
BB ask-user-to-execute-config.sys-line algorythm.
BB essentially (config.c, line 806 I think):
BB/* !device= never ask / device?= always ask / device= ask if singleStep */
BB/* ! does override singleStep but not ?, so !device?= will ask... */

 As I understand, currently behavior is this:

- 123? present and statement not from selected menu? Skip.
- ! present? Don't skip.
- ? present or single step? Ask.

Your proposal changes behavior: now it will look so:

- 123? present and statement not from selected menu? Skip.
- ? present? Ask.
- single step and not ! present? Ask.

 I think, this is valid.

BBif (! ( (singleStep  !DontAskThisSingleCommand) ||
BB(askThisSingleCommand) ) )
BB  return FALSE; /* do not skip, and do not ask either */

 This is identical to (simpler):

if ((!singleStep || DontAskThisSingleCommand) 
!askThisSingleCommand)
  return FALSE; /* do not skip, and do not ask either */

but I think this better will look so:

if (!(askThisSingleCommand ||   /* ? */
  singleStep  !DontAskThisSingleCommand)) /* not ! */
  return FALSE; /* do not skip, and do not ask either */

Well... I hardly rework config.c and fix many bugs (most of them are not
check input validness - for example, break=offk accepted as on). Also I
add above your changes. If you wish/can/may, I send you my config.c for
testing.




---
This SF.Net email is sponsored by The 2004 JavaOne(SM) Conference
Learn from the experts at JavaOne(SM), Sun's Worldwide Java Developer
Conference, June 28 - July 1 at the Moscone Center in San Francisco, CA
REGISTER AND SAVE! http://java.sun.com/javaone/sf Priority Code NWMGYKND
___
Freedos-kernel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freedos-kernel