From e2152132bd9dcddf43a7f540a7dc5b296a994df2 Mon Sep 17 00:00:00 2001
From: Denis Walker <dez@sucs.org>
Date: Sun, 4 Dec 2011 18:23:29 +0000
Subject: [PATCH] Woken up a bit and implemented the ndash fix in a way that
 actually works.

---
 components/motd.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/components/motd.php b/components/motd.php
index d1a3065..2e37c6d 100644
--- a/components/motd.php
+++ b/components/motd.php
@@ -10,7 +10,7 @@ function decode_entities($text, $quote_style = ENT_COMPAT) {
        $trans_tbl = array_flip($trans_tbl);
        $text = strtr($text, $trans_tbl);
    }
-   if ($text="&ndash;") $text = "-";
+   $text = preg_replace('&ndash;', '-', $text);
    $text = preg_replace('~&#x([0-9a-f]+);~ei', 'chr(hexdec("\\1"))', $text);
    $text = preg_replace('~&#([0-9]+);~e', 'chr("\\1")', $text);
    return $text;
-- 
GitLab