<!DOCTYPE html>
<html>
  <head>
  </head>
  <body>
    <dl style="line-height: 1.5; margin-left: 2em">
      <dt style="clear: both; float: left; font-weight: bold; width: 8em">Author</dt>
      <dd style="margin-left: 8.5em">susumu.yata &lt;susum****@gmail*****&gt;</dd>
      <dt style="clear: both; float: left; font-weight: bold; width: 8em">Date</dt>
      <dd style="margin-left: 8.5em">2015-10-19 13:42:46 +0900 (Mon, 19 Oct 2015)</dd>
      <dt style="clear: both; float: left; font-weight: bold; width: 8em">New Revision</dt>
      <dd style="margin-left: 8.5em"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9">14e634ab4890a4756e499543768ab732ea9bc1d9</a></dd>
      <dt style="clear: both; float: left; font-weight: bold; width: 8em">Message</dt>
      <dd style="margin-left: 8.5em"><pre style="border: 1px solid #aaa; font-family: Consolas, Menlo, &quot;Liberation Mono&quot;, Courier, monospace; line-height: 1.2; padding: 0.5em; width: auto">grn_pat: fix a bug of grn_pat_delete()

Note that this is a quick-fix approach.

GitHub: <a href="https://github.com/groonga/groonga/issues/420">#420</a></pre></dd>
      <dt style="clear: both; float: left; font-weight: bold; width: 8em">Modified files</dt>
      <dd style="margin-left: 8.5em">
        <ul>
          <li><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265f">lib/pat.c</a></li>
        </ul>
      </dd>
    </dl>

    <div class="diff-section" style="clear: both">
      <table style="border-collapse: collapse; border: 1px solid #aaa">
        <thead>
          <tr class="diff-header" style="border: 1px solid #aaa">
            <td colspan="3">
<pre style="border: 0; font-family: Consolas, Menlo, &quot;Liberation Mono&quot;, Courier, monospace; line-height: 1.2; margin: 0; padding: 0.5em; white-space: normal; width: auto"><span class="diff-header" style="background-color: #eaf2f5; color: #999999; display: block; white-space: pre">  Modified: lib/pat.c (+5 -0)</span>
<span class="diff-header-mark" style="background-color: #eaf2f5; color: #999999; display: block; white-space: pre">===================================================================</span>
</pre>
            </td>
          </tr>
        </thead>
        <tbody>
          <tr>
            <th class="diff-line-number" style="border: 1px solid #aaa">
<pre style="border: 0; font-family: Consolas, Menlo, &quot;Liberation Mono&quot;, Courier, monospace; line-height: 1.2; margin: 0; padding: 0.5em; white-space: normal; width: auto"><span class="diff-line-number-hunk-header" style="display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fL1098">...</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fL1099">1099</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fL1100">1100</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fL1101">1101</a></span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre">&nbsp;</span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre">&nbsp;</span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre">&nbsp;</span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre">&nbsp;</span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre">&nbsp;</span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fL1102">1102</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fL1103">1103</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fL1104">1104</a></span>
</pre>
            </th>
            <th class="diff-line-number" style="border: 1px solid #aaa">
<pre style="border: 0; font-family: Consolas, Menlo, &quot;Liberation Mono&quot;, Courier, monospace; line-height: 1.2; margin: 0; padding: 0.5em; white-space: normal; width: auto"><span class="diff-line-number-hunk-header" style="display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fR1098">...</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fR1099">1099</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fR1100">1100</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fR1101">1101</a></span>
<span class="diff-line-number-added" style="background-color: #dbffdb; color: #000000; display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fR1102">1102</a></span>
<span class="diff-line-number-added" style="background-color: #dbffdb; color: #000000; display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fR1103">1103</a></span>
<span class="diff-line-number-added" style="background-color: #dbffdb; color: #000000; display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fR1104">1104</a></span>
<span class="diff-line-number-added" style="background-color: #dbffdb; color: #000000; display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fR1105">1105</a></span>
<span class="diff-line-number-added" style="background-color: #dbffdb; color: #000000; display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fR1106">1106</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fR1107">1107</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fR1108">1108</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/groonga/groonga/commit/14e634ab4890a4756e499543768ab732ea9bc1d9#diff-e8f58132837f95fac7913a81cae2265fR1109">1109</a></span>
</pre>
            </th>
            <td class="diff-content" style="border: 1px solid #aaa">
<pre style="border: 0; font-family: Consolas, Menlo, &quot;Liberation Mono&quot;, Courier, monospace; line-height: 1.2; margin: 0; padding: 0.5em; white-space: normal; width: auto"><span class="diff-hunk-header" style="background-color: #eaf2f5; color: #999999; display: block; white-space: pre">@@ -1099,6 +1099,11 @@ <span class="diff-context" style="background-color: #ffffaa; color: #000000">_grn_pat_del(grn_ctx *ctx, grn_pat *pat, const char *key, uint32_t key_size, int</span></span>
<span class="diff-not-changed" style="display: block; white-space: pre">   uint32_t len = key_size * 16;</span>
<span class="diff-not-changed" style="display: block; white-space: pre">   grn_id r, otherside, *proot, *p, *p0 = NULL;</span>
<span class="diff-not-changed" style="display: block; white-space: pre"> </span>
<span class="diff-added" style="background-color: #dbffdb; color: #000000; display: block; white-space: pre">+  /* FIXME: This is a quick-fix approach. */</span>
<span class="diff-added" style="background-color: #dbffdb; color: #000000; display: block; white-space: pre">+  if (_grn_pat_get(ctx, pat, key, key_size, NULL) == GRN_ID_NIL) {</span>
<span class="diff-added" style="background-color: #dbffdb; color: #000000; display: block; white-space: pre">+    return GRN_INVALID_ARGUMENT;</span>
<span class="diff-added" style="background-color: #dbffdb; color: #000000; display: block; white-space: pre">+  }</span>
<span class="diff-added" style="background-color: #dbffdb; color: #000000; display: block; white-space: pre">+</span>
<span class="diff-not-changed" style="display: block; white-space: pre">   /* delinfo_new() must be called before searching for rn. */</span>
<span class="diff-not-changed" style="display: block; white-space: pre">   di = delinfo_new(ctx, pat);</span>
<span class="diff-not-changed" style="display: block; white-space: pre">   di-&gt;shared = shared;</span>
</pre>
            </td>
          </tr>
        </tbody>
      </table>
    </div>
  </body>
</html>