Skip to content
Permalink
Browse files

Misc fixes flush.

  • Loading branch information
valerius2k committed May 26, 2019
1 parent 6c0cbf3 commit ab153b5e267321caf4d656277e7828f3ec13478e
@@ -1,7 +1,3 @@
#define ID_APPNAME 1

#ifdef __LINUX__
POINTER ID_APPNAME "../shared/4os2.ico"
#else
POINTER ID_APPNAME "..\\shared\\4os2.ico"
#endif
@@ -1,6 +1,7 @@

PROJ = cmd
TRGT = $(PROJ).exe
PROJ = cmd1
PROJ1 = cmd
TRGT = $(PROJ1).exe
DESC = Command processor
srcfiles = $(p)main$(e) $(p)parser$(e) $(p)os2init$(e) $(p)cmds$(e) $(p)expand$(e) $(p)eval$(e) &
$(p)ea$(e) $(p)dircmds$(e) $(p)filecmds$(e) $(p)syscmds$(e) $(p)os2cmds$(e) &
@@ -12,12 +13,21 @@ ADD_COPT = -i=$(MYDIR)..$(SEP)include -i=$(MYDIR)..$(SEP)..$(SEP)include -ox
NODEFAULTLIBS = 1
# $(BLD)$(SEP)lib$(SEP)os2386.lib,
# clibext.lib,
#ADD_LINKOPT = lib os2386.lib, clib3r.lib, math387r.lib, emu387.lib, sub32.lib
#ADD_LINKOPT =
#STUB = $(FILESDIR)$(SEP)os2$(SEP)mdos$(SEP)$(PROJ).exe
RESOURCE = $(PATH)4os2.res
# ADD_LINKOPT = lib os2386.lib, clib3r.lib, math387r.lib, emu387.lib, sub32.lib
# ADD_LINKOPT =
inc = -i=. -i=$(MYDIR)..$(SEP)include -i=$(MYDIR)..$(SEP)..$(SEP)include &
-i=$(BLD)include # -i=$(BLD)include$(SEP)os2 -i=$(BLD)include$(SEP)shared
ADD_COPT += $(inc)
STUB = $(FILESDIR)$(SEP)os2$(SEP)mdos$(SEP)os2stub.exe
# RESOURCE = $(PATH)4os2.res
IMPORTS = DOSGETINFOSEG DOSCALLS.8
UNI2H = 1
#DEST = os2

!include $(%ROOT)/mk/appsos2_cmd.mk

TARGETS = $(PATH)$(PROJ1).exe

$(PATH)$(PROJ1).exe: $(PATH)$(PROJ).exe $(MYDIR)4os2.rc
@$(SAY) RESCMP $^. $(LOG)
$(RC) -bt=os2 -i=$(inc) $]@ $[@ -fe=$@ -fo=$(PATH)4os2.res
@@ -3,10 +3,6 @@

#define ID_RESOURCE 1

#ifdef __LINUX__
POINTER ID_RESOURCE "../shared/4os2.ico"
#else
POINTER ID_RESOURCE "..\\shared\\4os2.ico"
#endif

rcinclude "option2.dlg"
@@ -42,7 +42,7 @@ int dir_cmd (int argc, char **argv)
}

printf ("%s ", FindBuffer.achName); /* Print file name */
log ("%s ", FindBuffer.achName);
log ("dir: %s ", FindBuffer.achName);

/* Keep finding the next file until there are no more files */
for (;;)
@@ -58,7 +58,7 @@ int dir_cmd (int argc, char **argv)
break;

printf ("%s ", FindBuffer.achName); /* Print file name */
log ("%s ", FindBuffer.achName);
log ("dir: %s ", FindBuffer.achName);
}

rc = DosFindClose(hdirFindHandle); /* Close our directory handle */
@@ -12,7 +12,7 @@ APIRET APIENTRY DosOpenL(PCSZ pszFileName,
{
APIRET rc;
log("%s enter\n", __FUNCTION__);
log("pszFileName=%s\n", *pszFileName);
log("pszFileName=%s\n", pszFileName);
log("cbFile=%lld\n", cbFile);
log("ulAttribute=%lx\n", ulAttribute);
log("fsOpenFlags=%lx\n", fsOpenFlags);
@@ -14,7 +14,7 @@ DosQuerySysInfo(ULONG iStart, ULONG iLast,
log("cbBuf=%lu\n", cbBuf);

// for now
goto DOSQUERYSYSINFO_EXIT;
//goto DOSQUERYSYSINFO_EXIT;
//

if(iStart>iLast || pBuf==0)
@@ -241,14 +241,14 @@ APIRET APIENTRY DosQueryFileInfo(HFILE hf,
return rc;
}

APIRET APIENTRY DosQueryPathInfo(PCSZ pszPathName,
APIRET APIENTRY DosQueryPathInfo(PCSZ pszPathName,
ULONG ulInfoLevel,
PVOID pInfo,
ULONG cbInfoBuf)
{
APIRET rc;
log("%s enter\n", __FUNCTION__);
log("pszPathName=%lx\n", pszPathName);
log("pszPathName=%s\n", pszPathName);
log("ulInfoLevel=%lu\n", ulInfoLevel);
log("cbInfoBuf=%lu\n", cbInfoBuf);
rc = KalQueryPathInfo((PSZ)pszPathName, ulInfoLevel, pInfo, cbInfoBuf);
@@ -55,7 +55,7 @@ srcfiles = $(p)msg$(e) &
$(p)dossearchpath$(e) &
$(p)token$(e) &
$(p)monitors$(e) &
# $(p)viocalls$(e) &
$(p)viocalls$(e) &
$(p)dos16cwait$(e) &
$(p)vars$(e)

@@ -127,118 +127,118 @@ IMPORTS = &
_KalSuspendThread KAL.KalSuspendThread, &
_KalWaitThread KAL.KalWaitThread, &
_KalWrite KAL.KalWrite, &
WinDefAVioWindowProc EMXWRAP.30, &
WinDefAVioWindowProc SUB32.30, &
&
Vio32EndPopUp EMXWRAP.101, &
Vio32GetPhysBuf EMXWRAP.102, &
Vio32GetAnsi EMXWRAP.103, &
Vio32SetAnsi EMXWRAP.105, &
Vio32WrtTTY EMXWRAP.119, &
Vio32DeRegister EMXWRAP.106, &
Vio32ScrollUp EMXWRAP.107, &
Vio32PrtSc EMXWRAP.108, &
Vio32GetCurPos EMXWRAP.109, &
Vio32WrtCellStr EMXWRAP.110, &
Vio32PopUp EMXWRAP.111, &
Vio32ScrollRt EMXWRAP.112, &
Vio32WrtCharStr EMXWRAP.113, &
Vio32SetCurPos EMXWRAP.115, &
Vio32ScrUnLock EMXWRAP.118, &
Vio32GetMode EMXWRAP.121, &
Vio32SetMode EMXWRAP.122, &
Vio32ScrLock EMXWRAP.123, &
Vio32ReadCellStr EMXWRAP.124, &
Vio32SavRedrawWait EMXWRAP.125, &
Vio32WrtNAttr EMXWRAP.126, &
Vio32GetCurType EMXWRAP.127, &
Vio32SavRedrawUndo EMXWRAP.128, &
Vio32GetFont EMXWRAP.129, &
Vio32ReadCharStr EMXWRAP.130, &
Vio32GetBuf EMXWRAP.131, &
Vio32SetCurType EMXWRAP.132, &
Vio32SetFont EMXWRAP.133, &
Vio32ModeUndo EMXWRAP.135, &
Vio32ModeWait EMXWRAP.137, &
Vio32GetCp EMXWRAP.140, &
Vio32SetCp EMXWRAP.142, &
Vio32ShowBuf EMXWRAP.143, &
Vio32ScrollLf EMXWRAP.144, &
Vio32Register EMXWRAP.145, &
Vio32GetConfig EMXWRAP.146, &
Vio32ScrollDn EMXWRAP.147, &
Vio32WrtCharStrAtt EMXWRAP.148, &
Vio32GetState EMXWRAP.149, &
Vio32PrtScToggle EMXWRAP.150, &
Vio32SetState EMXWRAP.151, &
Vio32WrtNCell EMXWRAP.152, &
Vio32WrtNChar EMXWRAP.153, &
Vio32Associate EMXWRAP.155, &
Vio32CreatePS EMXWRAP.156, &
Vio32DeleteSetId EMXWRAP.157, &
Vio32GetDeviceCellSize EMXWRAP.158, &
Vio32GetOrg EMXWRAP.159, &
Vio32CreateLogFont EMXWRAP.160, &
Vio32DestroyPS EMXWRAP.161, &
Vio32QuerySetIds EMXWRAP.162, &
Vio32SetOrg EMXWRAP.163, &
Vio32QueryFonts EMXWRAP.164, &
Vio32SetDeviceCellSize EMXWRAP.165, &
Vio32ShowPS EMXWRAP.166, &
Vio32GlobalReg EMXWRAP.170, &
Vio32CheckCharType EMXWRAP.175, &
Vio32EndPopUp SUB32.101, &
Vio32GetPhysBuf SUB32.102, &
Vio32GetAnsi SUB32.103, &
Vio32SetAnsi SUB32.105, &
Vio32WrtTTY SUB32.119, &
Vio32DeRegister SUB32.106, &
Vio32ScrollUp SUB32.107, &
Vio32PrtSc SUB32.108, &
Vio32GetCurPos SUB32.109, &
Vio32WrtCellStr SUB32.110, &
Vio32PopUp SUB32.111, &
Vio32ScrollRt SUB32.112, &
Vio32WrtCharStr SUB32.113, &
Vio32SetCurPos SUB32.115, &
Vio32ScrUnLock SUB32.118, &
Vio32GetMode SUB32.121, &
Vio32SetMode SUB32.122, &
Vio32ScrLock SUB32.123, &
Vio32ReadCellStr SUB32.124, &
Vio32SavRedrawWait SUB32.125, &
Vio32WrtNAttr SUB32.126, &
Vio32GetCurType SUB32.127, &
Vio32SavRedrawUndo SUB32.128, &
Vio32GetFont SUB32.129, &
Vio32ReadCharStr SUB32.130, &
Vio32GetBuf SUB32.131, &
Vio32SetCurType SUB32.132, &
Vio32SetFont SUB32.133, &
Vio32ModeUndo SUB32.135, &
Vio32ModeWait SUB32.137, &
Vio32GetCp SUB32.140, &
Vio32SetCp SUB32.142, &
Vio32ShowBuf SUB32.143, &
Vio32ScrollLf SUB32.144, &
Vio32Register SUB32.145, &
Vio32GetConfig SUB32.146, &
Vio32ScrollDn SUB32.147, &
Vio32WrtCharStrAtt SUB32.148, &
Vio32GetState SUB32.149, &
Vio32PrtScToggle SUB32.150, &
Vio32SetState SUB32.151, &
Vio32WrtNCell SUB32.152, &
Vio32WrtNChar SUB32.153, &
Vio32Associate SUB32.155, &
Vio32CreatePS SUB32.156, &
Vio32DeleteSetId SUB32.157, &
Vio32GetDeviceCellSize SUB32.158, &
Vio32GetOrg SUB32.159, &
Vio32CreateLogFont SUB32.160, &
Vio32DestroyPS SUB32.161, &
Vio32QuerySetIds SUB32.162, &
Vio32SetOrg SUB32.163, &
Vio32QueryFonts SUB32.164, &
Vio32SetDeviceCellSize SUB32.165, &
Vio32ShowPS SUB32.166, &
Vio32GlobalReg SUB32.170, &
Vio32CheckCharType SUB32.175, &
&
KbdSetCustXt EMXWRAP.201, &
KbdGetCp EMXWRAP.203, &
KbdCharIn EMXWRAP.204, &
KbdSetCp EMXWRAP.205, &
KbdSynch EMXWRAP.207, &
KbdRegister EMXWRAP.208, &
KbdStringIn EMXWRAP.209, &
KbdGetStatus EMXWRAP.210, &
KbdSetStatus EMXWRAP.211, &
KbdGetFocus EMXWRAP.212, &
KbdFlushBuffer EMXWRAP.213, &
KbdXlate EMXWRAP.214, &
KbdClose EMXWRAP.217, &
KbdFreeFocus EMXWRAP.218, &
KbdDeRegister EMXWRAP.220, &
KbdSetFgnd EMXWRAP.221, &
KbdPeek EMXWRAP.222, &
KbdOpen EMXWRAP.223, &
KbdGetHWID EMXWRAP.224, &
KbdSetHWID EMXWRAP.225, &
KbdSetCustXt SUB32.201, &
KbdGetCp SUB32.203, &
KbdCharIn SUB32.204, &
KbdSetCp SUB32.205, &
KbdSynch SUB32.207, &
KbdRegister SUB32.208, &
KbdStringIn SUB32.209, &
KbdGetStatus SUB32.210, &
KbdSetStatus SUB32.211, &
KbdGetFocus SUB32.212, &
KbdFlushBuffer SUB32.213, &
KbdXlate SUB32.214, &
KbdClose SUB32.217, &
KbdFreeFocus SUB32.218, &
KbdDeRegister SUB32.220, &
KbdSetFgnd SUB32.221, &
KbdPeek SUB32.222, &
KbdOpen SUB32.223, &
KbdGetHWID SUB32.224, &
KbdSetHWID SUB32.225, &
&
MouGetPtrShape EMXWRAP.301, &
MouSetPtrShape EMXWRAP.302, &
MouGetNumMickeys EMXWRAP.303, &
MouGetScaleFact EMXWRAP.306, &
MouFlushQue EMXWRAP.307, &
MouGetNumButtons EMXWRAP.308, &
MouClose EMXWRAP.309, &
MouSetScaleFact EMXWRAP.311, &
MouGetNumQueEl EMXWRAP.313, &
MouDeRegister EMXWRAP.314, &
MouGetEventMask EMXWRAP.315, &
MouSetEventMask EMXWRAP.316, &
MouOpen EMXWRAP.317, &
MouRemovePtr EMXWRAP.318, &
MouGetPtrPos EMXWRAP.319, &
MouReadEventQue EMXWRAP.320, &
MouSetPtrPos EMXWRAP.321, &
MouGetDevStatus EMXWRAP.322, &
MouSynch EMXWRAP.323, &
MouRegister EMXWRAP.324, &
MouSetDevStatus EMXWRAP.325, &
MouDrawPtr EMXWRAP.326, &
MouInitReal EMXWRAP.327, &
MouSetThreshold EMXWRAP.329, &
MouGetThreshold EMXWRAP.330, &
MouGetPtrShape SUB32.301, &
MouSetPtrShape SUB32.302, &
MouGetNumMickeys SUB32.303, &
MouGetScaleFact SUB32.306, &
MouFlushQue SUB32.307, &
MouGetNumButtons SUB32.308, &
MouClose SUB32.309, &
MouSetScaleFact SUB32.311, &
MouGetNumQueEl SUB32.313, &
MouDeRegister SUB32.314, &
MouGetEventMask SUB32.315, &
MouSetEventMask SUB32.316, &
MouOpen SUB32.317, &
MouRemovePtr SUB32.318, &
MouGetPtrPos SUB32.319, &
MouReadEventQue SUB32.320, &
MouSetPtrPos SUB32.321, &
MouGetDevStatus SUB32.322, &
MouSynch SUB32.323, &
MouRegister SUB32.324, &
MouSetDevStatus SUB32.325, &
MouDrawPtr SUB32.326, &
MouInitReal SUB32.327, &
MouSetThreshold SUB32.329, &
MouGetThreshold SUB32.330, &
&
DosMonWrite EMXWRAP.401, &
DosMonRead EMXWRAP.402, &
DosMonClose EMXWRAP.403, &
DosMonOpen EMXWRAP.404, &
DosMonReg EMXWRAP.405
DosMonWrite SUB32.401, &
DosMonRead SUB32.402, &
DosMonClose SUB32.403, &
DosMonOpen SUB32.404, &
DosMonReg SUB32.405

EXPORTS = DosICreateThread .1, &
DOS16CWAIT .2, &
@@ -85,13 +85,13 @@ APIRET APIENTRY DosInsertMessage(PCHAR *pTable, ULONG cTable,
log("%s enter\n", __FUNCTION__);

// output args to log
log("cbMsg=%u", cbMsg);
log("pszMsg=");

//for (i = 0; i < cbMsg; i++)
for (i = 0; i < cbMsg; i++)
log("%c", pszMsg[i]);

log("\n");
log("cbMsg=%u", cbMsg);

log("cTable=%u\n", cTable);

0 comments on commit ab153b5

Please sign in to comment.