[Openvas-devel] 64 bit cleanless

Stjepan Gros sgros.ml at gmail.com
Sun Nov 9 15:09:35 CET 2008


I saw this mail just a few days ago but was unable to respond sooner because
I'm busy  lately with my everyday job. Comments are below.

On Thu, Oct 30, 2008 at 2:49 PM, Michael Wiegand <
michael.wiegand at intevation.de> wrote:

> [Thursday 16 October 2008 - 19:04:55] "Stjepan Gros" <sgros.ml at gmail.com>:
> > Ok, I went throught the code and included GLib in those subsystems that
> > didn't use it yet. I then inserted GPOINTER_TO_SIZE instead of (int) and
> > GSIZE_TO_POINTER instead of (void *). Furthermore, every occurence of
> > sizeof(int) I changed into sizeof(gpointer). There were few places where
> > sizeof(variable) was used, but I converted them also to sizeof(gpointer)
> as
> > it's the real size that is handed into the function. Few other omissions
> > were also corrected (but look into patches for them).
> Hello Stjepan,
> thank you very much for your patch; I'm sorry it took me a few days to get
> a
> good look at it.
> I've just finished going through you patch for -client and it looks very
> good
> so far. I would like to commit it to the SVN trunk soon, there are only a
> few
> minor issues:
> - I have noticed that you did not only fix the 64bit issue, but other
> issues
> as well. While this is definitely a great thing and more than welcome, it
> would be easier for other developers to understand your changes if you
> could
> split your patch (one patch for 64bit issues, one for others) and describe
> your changes in the appropriate ChangeLog.

I added ChangeLog entry. Also, I removed few non-64bit related changes whose
sole purpose was to get rid of some additional warnings. I'm going to send
those later, when this is applied, because it becomes hard for me to keep
all the changes I've done in sync with newest trunk.

Attached is patch for openvas-client only. If this is OK, then I'll send
patches for other subsystems as well.

- I have noticed that there are a few printf warnings on 32bit now after
> applying your patch, mostly along the lines of "format '%lu' expects
> type 'long unsigned int', but argument 3 has type 'unsigned int'". I'm not
> quite sure as to what would be the best way to solve this; you seem to have
> more experience in this area, any suggestions?

I totally forgot that it's going to generate warnings on 32-bit platforms.
Unfortunatelly, I don't know openvas so well to know how to definitely
resolve this issue. What I did now is that I added cast to change each
integer either 64-bit or 32-bit to 32-bit value. This is under the
assumption that those values will never be larger.

> Again, thank you very much for your patch, let me know if you have any
> questions.

Well, actually I do. What about those patches to move plugins into separate

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.wald.intevation.org/pipermail/openvas-devel/attachments/20081109/5a165d2a/attachment.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: openvas-client-64bit-v01.patch
Type: text/x-patch
Size: 23100 bytes
Desc: not available
Url : http://lists.wald.intevation.org/pipermail/openvas-devel/attachments/20081109/5a165d2a/openvas-client-64bit-v01-0001.bin

More information about the Openvas-devel mailing list