Hi, I was trying to figure out why CDE does not want to run on some
distros, including
the latest release of Fedora. These two patches are enough to get dtwm to
run.
The first is important, because it allows ToolTalk to work which dtwm is
reliant on (without the server starting
no tooltalk reliant program seems to be able to do anything at all).
The second is a hack for issues with font loading; I'm not sure it's the
"correct" hack even.
Still this does not seem to be enough to make starting full cde work yet,
but I send these patches
since finding the cause of tooltalk issue was a big pain.

-----------------------

For this first patch, ttsession (tooltalk daemon) was looping forever
polling /etc/mtab; it turns
out this is because in some distros (Fedora) it is a symlink of size zero.
Since the infinite loop which is caused is a workaround for something
ancient, it's probably
safe to just remove.

diff --git a/cde/lib/tt/lib/util/tt_file_system.C
b/cde/lib/tt/lib/util/tt_file_
index 8d98ff9..326694a 100644
--- a/cde/lib/tt/lib/util/tt_file_system.C
+++ b/cde/lib/tt/lib/util/tt_file_system.C
@@ -421,17 +421,6 @@ updateFileSystemEntries ()

        firsttime = 0;

-       // XXX Due to bug #1126575 - MNTTAB temporarily goes to
-       //     size 0 during automounter updates.  The file stats
-       //     OK, but has no data in it.
-       pollfd poll_fd;
-       while (mount_table_stat.st_size == 0) {
-               (void)poll (&poll_fd, 0, 100);
-               if (stat(TtMntTab, &mount_table_stat)) {
-                       return;
-                               }
-       }
-
        FILE *mount_table = ttOpenMntTbl(TtMntTab, "r");

        if (! mount_table) {


-------------------------------------------------

(This patch is much sketchier)

fontList ends up being an empty list, causing dtwm to exit.
Workaround by forcing load of "fixed" font.

diff --git a/cde/programs/dtwm/WmResource.c b/cde/programs/dtwm/WmResource.c
index 7c3d49c..c680dee 100644
--- a/cde/programs/dtwm/WmResource.c
+++ b/cde/programs/dtwm/WmResource.c
@@ -4431,9 +4431,9 @@ MakeAppearanceResources (WmScreenData *pSD,
AppearanceData

     if (! XmeRenderTableGetDefaultFont(pAData->fontList, &(pAData->font)))
     {
-       sprintf((char *)wmGD.tmpBuffer, ((char *)GETMESSAGE(62, 23, "failed
to l
-       Warning((char *)wmGD.tmpBuffer);
-       ExitWM(WM_ERROR_EXIT_VALUE);
+       /* HACK to get font anyway (fontList seems to end up NULL on
+         * some modern systems? */
+        pAData->font = XLoadQueryFont(wmGD.display, "fixed");
     }

 #ifndef NO_MULTIBYTE
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
cdesktopenv-devel mailing list
cdesktopenv-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/cdesktopenv-devel

Reply via email to