[Netnice-daemon] netniced Linux port
Status: Alpha
Brought to you by:
taost6
From: Sergei M. <mo...@no...> - 2003-11-12 17:20:34
|
Taka & team: Okay, here's another tiny patch and now we have netniced compiled for Linux! I have also managed to compile it with gcc -Wall, mostly by commenting out some variables that were declared but never used in the code. Please let me know if we need this patch as well. In addition, I have some general remarks about our code. First of all, in our header files, we never use common #ifndef/#define technique to prevent errors when the header is included twice in some source (directly or indirectly). I think we should add add such wrappers to each .h file - please see the classes.h patch attached for an example. I am also extremely confused with String, Integer, Boolean, Process, ProcessGroup etc. typedefs defined in the classes.h. It is very hard to tell from the code, whether, say, SocketGroup is an object or a pointer. Things get even more obscure if we decide to pass SocketGroup by reference or store it in an STL container. I would suggest to get rid of these typedefs completely in future. I have also noticed that some netniced classes, e.g. process, socket, processgroup, socketgroup, have a lot of things in common in both interface and implementation. Maybe it make sense to move the common functionality and/or interface to some generic base class and inherit from it. Thank you, Sergei. |