programming:python:pyradix_search_all_patch
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
programming:python:pyradix_search_all_patch [2008/07/05 20:58] – crustymonkey | programming:python:pyradix_search_all_patch [2008/07/05 21:28] – crustymonkey | ||
---|---|---|---|
Line 13: | Line 13: | ||
Usage: | Usage: | ||
< | < | ||
- | Radix.search_all_containing(< | + | Radix.search_all_containing(< |
</ | </ | ||
<code python> | <code python> | ||
Line 61: | Line 61: | ||
Here is the code for the patch, followed by a link to the file. | Here is the code for the patch, followed by a link to the file. | ||
< | < | ||
- | --- radix_python.c | + | --- radix_python.c |
- | +++ radix_python.c.new | + | +++ radix_python.c.new |
- | @@ -453,6 +453,53 @@ | + | @@ -453,6 +453,52 @@ |
return (PyObject *)node_obj; | return (PyObject *)node_obj; | ||
} | } | ||
Line 89: | Line 89: | ||
+ long prefixlen = -1; | + long prefixlen = -1; | ||
+ int packlen = -1; | + int packlen = -1; | ||
+ | + | ||
+ | + | ||
+ if (!PyArg_ParseTupleAndKeywords(args, | + if (!PyArg_ParseTupleAndKeywords(args, | ||
Line 99: | Line 100: | ||
+ | + | ||
+ | + | ||
- | + | + | + |
- | + | + | |
+ } | + } | ||
+ | + | ||
- | + | ||
+ | + | ||
+ | + | ||
Line 117: | Line 116: | ||
" | " | ||
\n\ | \n\ | ||
- | @@ -640,6 +687,7 @@ | + | @@ -640,6 +686,7 @@ |
{" | {" | ||
{" | {" | ||
Line 130: | Line 129: | ||
===== Patching ===== | ===== Patching ===== | ||
- | - Download the above patch file | + | Download the above patch file and do the following: |
- | - '' | + | < |
- | - '' | + | # cp radix_python.c.patch.gz / |
- | - '' | + | # cd / |
- | - '' | + | # gunzip radix_python.c.patch.gz |
- | - Run the normal install for the py-radix module: '' | + | # patch -p0 radix_python.c < radix_python.c.patch |
+ | # python setup.py install | ||
+ | </ | ||
+ | The last line there will install the patched module. | ||
programming/python/pyradix_search_all_patch.txt · Last modified: 2008/07/05 22:10 by crustymonkey