Index: trunk/src/helpers/dosh.c
===================================================================
--- trunk/src/helpers/dosh.c	(revision 216)
+++ trunk/src/helpers/dosh.c	(revision 217)
@@ -3749,13 +3749,19 @@
 
         // resolve DosPerfSysCall API entry
-        if (!(arc = DosLoadModule(NULL, 0, "DOSCALLS", &pPerfSys->hmod)))
+        if (!(arc = DosLoadModule(NULL,
+                                  0,
+                                  "DOSCALLS",
+                                  &pPerfSys->hmod)))
         {
             if (!(arc = DosQueryProcAddr(pPerfSys->hmod,
                                          976,
                                          "DosPerfSysCall",
-                                         (PFN*)(&pPerfSys->pDosPerfSysCall))))
+                                         (PFN*)&pPerfSys->pDosPerfSysCall)))
             {
                 // OK, we got the API: initialize!
-                if (!(arc = pPerfSys->pDosPerfSysCall(CMD_KI_ENABLE, 0, 0, 0)))
+                if (!(arc = pPerfSys->pDosPerfSysCall(CMD_KI_ENABLE,
+                                                      0,
+                                                      0,
+                                                      0)))
                 {
                     pPerfSys->fInitialized = TRUE;
@@ -3764,5 +3770,5 @@
                     if (!(arc = pPerfSys->pDosPerfSysCall(CMD_PERF_INFO,
                                                           0,
-                                                          (ULONG)(&pPerfSys->cProcessors),
+                                                          (ULONG)&pPerfSys->cProcessors,
                                                           0)))
                     {
Index: trunk/src/helpers/except.c
===================================================================
--- trunk/src/helpers/except.c	(revision 216)
+++ trunk/src/helpers/except.c	(revision 217)
@@ -451,4 +451,5 @@
  *@@changed V0.9.16 (2001-11-02) [pr]: make object display signed
  *@@changed V0.9.19 (2002-03-28) [umoeller]: added thread ordinal
+ *@@changed V0.9.21 (2002-08-28) [umoeller]: added OS revision to dump
  */
 
@@ -507,5 +508,5 @@
     // generic exception info
     DosQuerySysInfo(QSV_VERSION_MAJOR,      // 11
-                    QSV_VERSION_MINOR,      // 12
+                    QSV_VERSION_REVISION,   // 13 V0.9.21 (2002-08-28) [umoeller]
                     &aulBuf, sizeof(aulBuf));
     // Warp 3 is reported as 20.30
@@ -523,7 +524,8 @@
     }
     fprintf(file,
-            "Running OS/2 version: %u.%u (%s)\n",
+            "Running OS/2 version: %u.%u.%u (%s)\n",
             aulBuf[0],                      // major
             aulBuf[1],
+            aulBuf[2],              // revision V0.9.21 (2002-08-28) [umoeller]
             pcszVersion);
 
Index: trunk/src/helpers/procstat.c
===================================================================
--- trunk/src/helpers/procstat.c	(revision 216)
+++ trunk/src/helpers/procstat.c	(revision 217)
@@ -92,9 +92,4 @@
     APIRET arc = NO_ERROR;
     PQPROCSTAT16 pps = NULL;
-
-    /* PQPROCSTAT16 pps = (PQPROCSTAT16)malloc(0x8000);
-    if (!pps)
-        arc = ERROR_NOT_ENOUGH_MEMORY;
-    else */
 
     if (!ppps)
@@ -340,5 +335,5 @@
                   pProcess->ulType != 3;
                   pProcess = (PQPROCESS16)PTR(pProcess->ulThreadList,
-                             pProcess->usThreads * sizeof(QTHREAD16))
+                                              pProcess->usThreads * sizeof(QTHREAD16))
                 )
             {
Index: trunk/src/helpers/winh.c
===================================================================
--- trunk/src/helpers/winh.c	(revision 216)
+++ trunk/src/helpers/winh.c	(revision 217)
@@ -67,4 +67,5 @@
 #define INCL_WINCIRCULARSLIDER
 #define INCL_WINSTDFILE
+#define INCL_WINCLIPBOARD
 
 #define INCL_SPL
@@ -4705,4 +4706,48 @@
 
 /*
+ *@@ winhSetClipboardText:
+ *      sets the clipboard data to the given text,
+ *      replacing the current clipboard contents.
+ *
+ *@@added V0.9.21 (2002-08-28) [umoeller]
+ */
+
+BOOL winhSetClipboardText(HAB hab,
+                          PCSZ pcsz,
+                          ULONG cbSize)     // in: size of buffer INCLUDING null byte
+{
+    BOOL    fSuccess = FALSE;
+
+    if (WinOpenClipbrd(hab))
+    {
+        PSZ pszDest;
+        if (!DosAllocSharedMem((PVOID*)&pszDest,
+                               NULL,
+                               cbSize,
+                               PAG_WRITE | PAG_COMMIT | OBJ_GIVEABLE))
+        {
+            memcpy(pszDest,
+                   pcsz,
+                   cbSize);
+
+            WinEmptyClipbrd(hab);
+
+            fSuccess = WinSetClipbrdData(hab,       // anchor-block handle
+                                         (ULONG)pszDest, // pointer to text data
+                                         CF_TEXT,        // data is in text format
+                                         CFI_POINTER);   // passing a pointer
+
+            // PMREF says (implicitly) it is not necessary to call
+            // DosFreeMem. I hope that is correct.
+            // V0.9.19 (2002-06-02) [umoeller]
+        }
+
+        WinCloseClipbrd(hab);
+    }
+
+    return fSuccess;
+}
+
+/*
  *@@category: Helpers\PM helpers\Extended frame windows
  */
@@ -4953,10 +4998,10 @@
     {
         // allocate buffer
-        pObjClass = (POBJCLASS)malloc(ulSize+1);
+        pObjClass = (POBJCLASS)malloc(ulSize + 1);
         // and load the classes into it
         WinEnumObjectClasses(pObjClass, &ulSize);
     }
 
-    return ((PBYTE)pObjClass);
+    return (PBYTE)pObjClass;
 }
 
