mhonarc-users

Re: help;msdos install.me

1996-03-11 15:56:31
when i run the install me script I get the following error message 
"unmatched [] mregexp at install.me line 48".  I'm running perl version 
4.0m1;4.0.1.8 patch level 36.  I looked at the line of text but nothing 
seems obvious to me.

The problem is that $'DIRSEP will expand to a backslash, and the
backslash needs to be escaped.

Since the offending line it not needed for the execution of the
program, you can comment out the line, or delete it.

BTW, this bug will show up in osinit.pl in the lib directory (line
67).  The expression needs to be modified to escape the $'DIRSEP
variable in case it may contain special characters.  Fixing this will
avoid an error when running mhonarc.  The following should work:

Change

    ##  Store name of program
    ($'PROG = $0) =~ s%.*[$'DIRSEP]%%o;

to

    ##  Store name of program
    ($tmp = $'DIRSEP) =~ s/(\W)/\\$1/g;
    ($'PROG = $0) =~ s%.*[$tmp]%%o;


Note, you can also apply this change to the install.me program.

        --ewh

<Prev in Thread] Current Thread [Next in Thread>