A question and a little problem

From: Rafael Corvalan (rafael@filnet.fr)
Date: Wed Feb 28 1996 - 00:47:55 CET


CTWM version : 3.3

        Hi,

        First at all (the simpliest question) :
        somebody knows a good pixmap editor ?

        Second question :

        I've found a very little "problem" (it isn't really
        a problem) using ctwm on a Sun Solaris machine.

        Compilation was OK, but when running ctwm, I have a
        warning saying that there was too much parameters to
        a 'define' macro.

        The "problem" is that the file parse.c creates some
        macros that are parsed by m4, and these macros don't
        quote the parameters. And for ther VENDOR macro, on
        a Sun under Sun Solaris, it results on a macro call
        that SEEMS to

define(VENDOR, Sun Solaris, xxxx)

        so, the ',' on the VENDOR name causes trouble. I made some
        change on my side to the file parse.c but it's the first time I
        do something like that, so I'm not sure of doing memory
        lakes. If someone is good enough to patch this, here's
        my idea :

        On file parse.c :

change the EXTRA cpp macro to allocate memery for the 4 new characters
#define EXTRA 12
changes to
#define EXTRA 16

modify the function static char *MkDef(name, def) to insert
the characters ` and ' around the name and the def like :

        strcpy(cp, "define(`");
        strcpy(cp+8, name);
        *(cp + nl + 8) = ',';
        *(cp + nl + 9) = ' ';
        strcpy(cp + nl + 10, def);
        strcat(cp + nl + 10, "')\n");

        This isn't a perfect solution, because if one of the
        items contains a quote ...... :-((

                Any comments ?

        

                                \\|//
                                (o o)
 +--------------------------oOO--(_)--OOo---------------------------+
 | |
 | Rafael Corvalan ("`-''-/").___..--''"`-._ |
 | `6_ 6 ) `-. ( ).`-.__.`) |
 | e-mail: rafael@filnet.fr (_Y_.)' ._ ) `._ `. ``-..-' |
 | _..`--'_..-_/ /--'_.' ,' |
 | (il),-'' (li),' ((!.-' |
 | |
 +------------------------------------------------------------------+

--BAA09644.825467930/leonardo.lls.se--

% ====== Internet headers and postmarks (see DECWRL::GATEWAY.DOC) ======
% Received: from mail11.digital.com by us2rmc.zko.dec.com (5.65/rmc-22feb94) id AA09054; Tue, 27 Feb 96 20:33:23 -050
% Received: from cognac.epfl.ch by mail11.digital.com (5.65v3.2/1.0/WV) id AA08128; Tue, 27 Feb 1996 20:33:31 -050
% Message-Id: <9602280133.AA08128@mail11.digital.com>
% Received: by cognac.epfl.ch (1.39.111.2/16.2) id AA249628960; Wed, 28 Feb 1996 01:56:00 +010
% Date: Wed, 28 Feb 1996 01:56:00 +0100
% From: ctwm@cognac.epfl.ch
% Errors-To: ctwm-errors@cognac.epfl.ch
% Apparently-To: ctwm-actual@cognac.epfl.ch



This archive was generated by hypermail 2.1.2 : Sat Jun 22 2002 - 06:45:02 CEST