gnunet-developers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [GNUnet-developers] gnunet-search and URIs


From: Christian Grothoff
Subject: Re: [GNUnet-developers] gnunet-search and URIs
Date: Tue, 10 Feb 2009 20:30:34 -0700
User-agent: KMail/1.10.3 (Linux/2.6.27-11-generic; KDE/4.1.3; i686; ; )

Looks like a very reasonable place to put the code.  I've cleaned it up a bit, 
it's now in SVN, revision 8215.

Thanks!

Christian

On Tuesday 10 February 2009 02:12:21 pm Yunta wrote:
> Hi,
>
> gnunet-search's man says you can give it URI instead of keywords
> it didn't work for me (rev 8213), so I wrote this:
>
>
> Index: src/applications/fs/ecrs/helper.c
> ===================================================================
> --- src/applications/fs/ecrs/helper.c (revision 8213)
> +++ src/applications/fs/ecrs/helper.c (working copy)
> @@ -160,6 +160,18 @@
>
>    if (num_keywords == 0)
>      return NULL;
> +
> +  if (num_keywords == 1)
> +    {
> +      if (strlen(keywords[0])>strlen(GNUNET_ECRS_URI_PREFIX))
> +        {
> +          if
> (strncmp(keywords[0],GNUNET_ECRS_URI_PREFIX,strlen(GNUNET_ECRS_URI_PREFIX))
> == 0)
> +            {
> +              return GNUNET_ECRS_string_to_uri(ectx, keywords[0]);
> +            }
> +        }
> +    }
> +
>    uri = GNUNET_malloc (sizeof (URI));
>    uri->type = ksk;
>    uri->data.ksk.keywordCount = num_keywords;
>
>
> and it works (or just looks like it's working)
> I don't know gnunet's code (it took me 1 hour to write this) so it can
> be totally wrong.
> And probably it is placed incorrectly.
> Anyway, it may be better than nothing :)
>
>
> br,
> yunta
>
> ps.
> thank you all for writing gnunet, for your effort, time and result
>
>
> _______________________________________________
> GNUnet-developers mailing list
> address@hidden
> http://lists.gnu.org/mailman/listinfo/gnunet-developers





reply via email to

[Prev in Thread] Current Thread [Next in Thread]