From 5dfd4cb46c9977ff3c4bed404723cee88554bf21 Mon Sep 17 00:00:00 2001 From: Jon Ciesla Date: Jun 30 2014 14:10:43 +0000 Subject: Patch fix. --- diff --git a/abiword-3.0.0-link-grammar-5.patch b/abiword-3.0.0-link-grammar-5.patch index bd91735..bbf75f6 100644 --- a/abiword-3.0.0-link-grammar-5.patch +++ b/abiword-3.0.0-link-grammar-5.patch @@ -1,43 +1,45 @@ ---- abiword-3.0.0/plugins/grammar/linkgrammarwrap/LinkGrammarWrap.cpp.orig 2013-04-07 08:53:03.000000000 -0500 -+++ abiword-3.0.0/plugins/grammar/linkgrammarwrap/LinkGrammarWrap.cpp 2014-06-27 08:58:42.186089562 -0500 -@@ -145,11 +145,11 @@ +--- abiword-3.0.0/plugins/grammar/linkgrammarwrap/LinkGrammarWrap.cpp.orig 2014-06-29 14:50:30.000000000 -0500 ++++ abiword-3.0.0/plugins/grammar/linkgrammarwrap/LinkGrammarWrap.cpp 2014-06-29 14:55:39.000000000 -0500 +@@ -145,12 +145,11 @@ bool LinkGrammarWrap::parseSentence(Piec } AbiGrammarError * pWordMap = new AbiGrammarError(); pWordMap->m_iErrLow = iLow; - pWordMap->m_iErrHigh = iLow + strlen(sentence_get_nth_word(sent, i)); -+ pWordMap->m_iErrHigh = iLow + sentence_link_cost(sent, i); ++ pWordMap->m_iErrHigh = iLow + strlen(linkage_get_word(linkage, i)); pWordMap->m_iWordNum = i; vecMapOfWords.addItem(pWordMap); bool bNew = false; - if(!sentence_nth_word_has_disjunction(sent, i)) -+ if(!sentence_disjunct_cost(sent, i)) - { +- { ++ //UT_DEBUGMSG(("|%s| NULL LINK\n",sent->word[i].string)); if(pErr == NULL) -@@ -167,7 +167,7 @@ + { +@@ -167,7 +166,7 @@ bool LinkGrammarWrap::parseSentence(Piec } pErr = new AbiGrammarError(); } - iHigh = iLow + strlen(sentence_get_nth_word(sent, i)); -+ iHigh = iLow + sentence_link_cost(sent, i); ++ iHigh = iLow + strlen(linkage_get_word(linkage, i)); pErr->m_iErrLow = iLow + iOff -1; pErr->m_iErrHigh = iHigh + iOff -1; if(pErr->m_iErrLow < 0) -@@ -188,7 +188,7 @@ +@@ -188,7 +187,7 @@ bool LinkGrammarWrap::parseSentence(Piec // // Expand the sqiggle // - iHigh = iLow + strlen(sentence_get_nth_word(sent, i)) + iOff; -+ iHigh = iLow + sentence_link_cost(sent, i) + iOff; ++ iHigh = iLow + strlen(linkage_get_word(linkage, i)) + iOff; pErr->m_iErrHigh = iHigh; if(pErr->m_iErrHigh < totlen-1) { -@@ -197,7 +197,7 @@ +@@ -196,8 +195,7 @@ bool LinkGrammarWrap::parseSentence(Piec + } pErr->m_iWordNum = i; } - } +- } - iLow += strlen(sentence_get_nth_word(sent, i)); -+ iLow += sentence_link_cost(sent, i); ++ iLow += strlen(linkage_get_word(linkage, i)); } // // No NULL links but still an error , mark the whole sentence bad. diff --git a/abiword.spec b/abiword.spec index 770e399..33997ac 100644 --- a/abiword.spec +++ b/abiword.spec @@ -6,7 +6,7 @@ Summary: Word processing program Name: abiword Version: %{majorversion}.%{minorversion}.%{microversion} -Release: 10%{?dist} +Release: 11%{?dist} Epoch: 1 Group: Applications/Editors License: GPLv2+ @@ -203,6 +203,9 @@ fi %{python_sitearch}/* %changelog +* Mon Jun 30 2014 Jon Ciesla - 1:3.0.0-11 +- Corrected patch from Linas Vepstas. + * Tue Jun 24 2014 Jon Ciesla - 1:3.0.0-10 - Rebuild for new link-grammar, with patch for API change. - Add librevenge BuildRequires, modified patch for current librevenge header placement.