unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
blob 2a57a31a08aa10e6dd68bb9910ec1b1c9f6a78ca 1334 bytes (raw)
name: gnu/packages/patches/swish-e-search.patch 	 # note: path name is non-authoritative(*)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
 
From http://swish-e.org/archive/2015-09/13295.html

--- a/src/compress.c	
+++ a/src/compress.c	
@@ -995,7 +995,7 @@ void    remove_worddata_longs(unsigned char *worddata,int *sz_worddata)
             progerr("Internal error in remove_worddata_longs");
 
         /* dst may be smaller than src. So move the data */
-        memcpy(dst,src,data_len);
+        memmove(dst,src,data_len);
 
         /* Increase pointers */
         src += data_len;
--- a/src/headers.c	
+++ a/src/headers.c	
@@ -280,7 +280,7 @@ static SWISH_HEADER_VALUE fetch_single_header( IndexFILE *indexf, HEADER_MAP *he
 
         case SWISH_NUMBER:
         case SWISH_BOOL:
-            value.number = *(unsigned long *) data_pointer;
+            value.number = *(unsigned int *) data_pointer;
 
             /* $$$ Ugly hack alert! */
             /* correct for removed files */
--- a/src/swishspider	
+++ a/src/swishspider	
@@ -27,6 +27,7 @@ use LWP::UserAgent;
 use HTTP::Status;
 use HTML::Parser 3.00;
 use HTML::LinkExtor;
+use Encode;
 
     if (scalar(@ARGV) != 2) {
         print STDERR "Usage: $0 localpath url\n";
@@ -94,7 +95,7 @@ use HTML::LinkExtor;
     # Don't allow links above the base
     $URI::ABS_REMOTE_LEADING_DOTS = 1;
 
-    $p->parse( $$content_ref );
+    $p->parse( decode_utf8 $$content_ref );
     close( LINKS );
 
     exit;

debug log:

solving 2a57a31 ...
found 2a57a31 in https://git.savannah.gnu.org/cgit/guix.git

(*) Git path names are given by the tree(s) the blob belongs to.
    Blobs themselves have no identifier aside from the hash of its contents.^

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).