FreeBSD Bugzilla – Attachment 208405 Details for
Bug 241327
mail/roundcube: Broken NSC option
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
roundcube.diff
roundcube.diff (text/plain), 4.27 KB, created by
Tobias Kortkamp
on 2019-10-18 13:54:57 UTC
(
hide
)
Description:
roundcube.diff
Filename:
MIME Type:
Creator:
Tobias Kortkamp
Created:
2019-10-18 13:54:57 UTC
Size:
4.27 KB
patch
obsolete
>Index: mail/roundcube/Makefile >=================================================================== >--- mail/roundcube/Makefile (revision 514718) >+++ mail/roundcube/Makefile (working copy) >@@ -2,6 +2,7 @@ > > PORTNAME= roundcube > DISTVERSION= 1.3.9 >+PORTREVISION= 1 > PORTEPOCH= 1 > CATEGORIES?= mail www > MASTER_SITES= https://github.com/roundcube/roundcubemail/releases/download/${DISTVERSION}/ >@@ -28,7 +29,7 @@ > > USE_PHP= pcre mbstring session iconv dom xml json intl zip filter openssl fileinfo exif > >-OPTIONS_DEFINE= LDAP GD PSPELL NSC DOCS EXAMPLES >+OPTIONS_DEFINE= LDAP GD PSPELL DOCS EXAMPLES > OPTIONS_MULTI= DB > OPTIONS_MULTI_DB= MYSQL PGSQL SQLITE > OPTIONS_DEFAULT=MYSQL >@@ -40,13 +41,10 @@ > LDAP_DESC= Enable LDAP support (address book) > GD_DESC= Enable GD support (image conversion) > PSPELL_DESC= Enable PSpell support (internal spellcheck) >-NSC_DESC= Install network spellchecker > > GD_VARS= use_php+=gd > LDAP_VARS= use_php+=ldap > MYSQL_VARS= use_php+=pdo_mysql >-NSC_IMPLIES= PSPELL >-NSC_VARS= use_php+=simplexml rcubecomp+=spellchecker.php > PGSQL_VARS= use_php+=pdo_pgsql > PSPELL_VARS= use_php+=pspell > SQLITE_VARS= use_php+=pdo_sqlite >@@ -53,9 +51,6 @@ > > SUB_FILES= newsyslog.conf > >-post-extract-NSC: >- @${CP} ${FILESDIR}/spellchecker.php ${WRKSRC} >- > post-patch: > @${FIND} ${WRKSRC} -name \*.orig -type f -delete > >Index: mail/roundcube/files/spellchecker.php >=================================================================== >--- mail/roundcube/files/spellchecker.php (revision 514718) >+++ mail/roundcube/files/spellchecker.php (nonexistent) >@@ -1,53 +0,0 @@ >-<?php >-/*- >- * Copyright (c) 2006 Alex Dupre. All rights reserved. >- * >- * Redistribution and use in source and binary forms, with or without >- * modification, are permitted provided that the following conditions >- * are met: >- * 1. Redistributions of source code must retain the above copyright >- * notice, this list of conditions and the following disclaimer. >- * 2. Redistributions in binary form must reproduce the above copyright >- * notice, this list of conditions and the following disclaimer in the >- * documentation and/or other materials provided with the distribution. >- * >- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR >- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES >- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. >- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, >- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT >- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, >- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY >- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT >- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF >- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. >- */ >-$lang = $_REQUEST["lang"]; >-$xml = new SimpleXMLElement(file_get_contents("php://input")); >-$spell = pspell_new($lang, "", "", "utf-8", PSPELL_NORMAL); >-$suggestions = array(); >-$offset = 0; >-mb_regex_encoding("UTF-8"); >-foreach (mb_split("\n", $xml->text) as $line) { >- $len = mb_strlen($line, "UTF-8"); >- mb_ereg_search_init($line, "\w+"); >- while (($wpos = mb_ereg_search_pos()) != FALSE) { >- $word = mb_substr($line, $wpos[0], $wpos[1]); >- if (!pspell_check($spell, $word)) { >- $woffset = mb_strlen(mb_substr($line, 0, $wpos[0]), "UTF-8"); >- $wlen = mb_strlen($word, "UTF-8"); >- array_push($suggestions, array($offset + $woffset, $wlen, pspell_suggest($spell, $word))); >- } >- } >- $offset += $len + 1; >-} >-$xml = new SimpleXMLElement("<spellresponse/>"); >-$xml->addAttribute("error", count($suggestions) ? "1" : "0"); >-foreach ($suggestions as $s) { >- $c = $xml->addChild("c", join("\t", $s[2])); >- $c->addAttribute("o", $s[0]); >- $c->addAttribute("l", $s[1]); >- $c->addAttribute("s", "1"); >-} >-header('Content-Type: text/xml'); >-echo $xml->asXML(); > >Property changes on: mail/roundcube/files/spellchecker.php >___________________________________________________________________ >Deleted: fbsd:nokeywords >## -1 +0,0 ## >-yes >\ No newline at end of property >Deleted: svn:eol-style >## -1 +0,0 ## >-native >\ No newline at end of property >Deleted: svn:mime-type >## -1 +0,0 ## >-text/plain >\ No newline at end of property
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
tobik
:
maintainer-approval?
(
ale
)
Actions:
View
|
Diff
Attachments on
bug 241327
: 208405