Title: die error regarding unicode/environment variable on NT/regex usage

I get the following error:

Can't find unicode character property definition via main->E or E.pl at unicode/
Is/E.pl line 0

and have narrowed its cause to be the s|$1||; line, but don't know why.. 

      if($system_path =~ m|(\Q$ENV{'APPSDIR'}\E\\PERL\\BIN)|i)
        {
           print "Original PATH: $system_path\n";

           $system_path =~ s|$1||;

           $reg_obj->SetValue("PATH", "$system_path", 'REG_EXPAND_SZ');

           print "New PATH: $system_path\n";
        }

The background behind this snippit is I'm modifying the PATH variable via the registry on an NT system, and I'm pulling in the contents of an environment variable.  I'm not intentionally using anything unicode, I think it somehow crept into my code.  Perhaps NT environment variables are unicode, and since I'm using one in the regex its lousing up my substitution?  I did look in some books, but the answer was not forthcoming.  I'd like to force a non-unicode usage of $ENV{APPSDIR}(or assign it to another variable and force the non-unicode on that var).  All my registry stuff is being done with Win32::TieRegistry. 

Any ideas/insight appreciated.

thanks,
 marc

Reply via email to