Bug List: (This bug is not in your last search results)   Show last search results      Search page      Enter new bug
Bug#: 159786
Alias:
Product:
Component:
Status: CLOSED
Resolution: TEST-REQUEST
Assigned To: Netmon Herd <netmon@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Lars T. Mikkelsen <ltm@mulm.dk>
Add CC:
CC:
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
mrtg.rc.patch mrtg.rc.patch patch Lars T. Mikkelsen 2007-01-02 15:08 0000 355 bytes Details | Diff
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 159786 depends on: Show dependency tree
Bug 159786 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.




View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2007-01-02 15:07 0000
If using a UTF-8 locale and Bash 3.2 the mrtg init script fails set LANG=C
required for mrtg to run. The original issue with UTF-8 locales was fixed in
bug 132652, but when using Bash 3.2 the regular expression used fails.
According to the Wikipedia entry for Bash "the regular expression begins with
the first non-whitespace character after =~" as of Bash 3.2. The attached patch
removes the single quotes form the regular expression and thus fixing the
issue. I haven't tested how this affects versions prior to 3.2.

------- Comment #1 From Lars T. Mikkelsen 2007-01-02 15:08:40 0000 -------
Created an attachment (id=105248) [details]
mrtg.rc.patch

------- Comment #2 From Cédric Krier 2007-01-03 14:56:40 0000 -------
Replace with a grep
Fix in cvs

------- Comment #3 From Lars T. Mikkelsen 2007-01-03 23:53:59 0000 -------
Thanks, the fix works. Closing bug.

------- Comment #4 From Denis Knauf 2007-01-11 10:59:48 0000 -------
better, use this:
echo "$LANG" | grep -E '((^[A-Za-z0-9\_\@\-]+\.)|(^))([uU][tT][fF]-?8)$' &&
LANG='C'

it's faster and needn't the [[ ]]-crap.

Bug List: (This bug is not in your last search results)   Show last search results      Search page      Enter new bug