gnunet-developers
[Top][All Lists]
Advanced

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

Re: Let BIO also handle already allocated buffers


From: Florian Dold
Subject: Re: Let BIO also handle already allocated buffers
Date: Sun, 19 Apr 2020 18:02:14 +0530
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.6.0

Hi *,

On 4/19/20 5:31 PM, Alessio Vanni wrote:
> In my opinion, a nicer approach could be something based on Java's
> Buffer object from the NIO package.  For example (again no error
> checking; also the names could use some more work):

We already have something exactly like that:

https://git.gnunet.org/gnunet.git/tree/src/include/gnunet_buffer_lib.h

Maybe it makes more sense to add new functionality to the buffer lib?
I.e., teach the buffer lib to read from / write to files, in a similar
fashion to the Java NIO that you've mentioned.  We can also add some
other ways to read/parse data, such as the ones Christian suggested.

Then we can remove BIO eventually, as it's not a nice API
("abomination") and sits at a weird level of abstraction.

- Florian



reply via email to

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