summaryrefslogtreecommitdiffstats
path: root/include/libcgroup/iterators.h
Commit message (Collapse)AuthorAgeFilesLines
* add const where applicable, drop const where unnecessaryLennart Poettering2010-03-261-4/+4
| | | | | | | | | | | | | | | This patch adds the const qualifier to a number of function arguments (mostly string arguments) so that client libraries can pass their own const strings to the library without having to cast their const'ness away. This also drops a couple of consts where call-by-value is done anyway, and which hence has no effect and just misleads the users and adds unnecessary noise to the signal. After all this is C, not C++. Signed-off-by: Lennart Poettering <lennart@poettering.net> Acked-by: Dhaval Giani <dhaval.giani@gmail.com> Signed-off-by: Dhaval Giani <dhaval.giani@gmail.com>
* include: refuse inclusion of seperate header filesLennart Poettering2010-03-241-0/+4
| | | | | | | | | | | Later on it might make sense to move around function definitions between header files. Hence make sure that nobody includes any header file directly except the main one. Signed-off-by: Lennart Poettering <lennart@poettering.net> Reviewed-By: Jan Safranek <jsafrane@redhat.com> Acked-by: Dhaval Giani <dhaval.giani@gmail.com> Signed-off-by: Dhaval Giani <dhaval.giani@gmail.com>
* Split header file IIIJan Safranek2010-03-211-0/+170
Changelog: - since there are no global macros, base.h is gone - since there is no base.h, all headers need to include <features.h> to get __BEGIN_DECLS - new init.h with cgroup_init() and cgroup_get_subsys_mount_point() - new error.h with error handling enum and related stuff - use #ifndef _LIBCGROUP_*_H instead _LIBCG_*_H in header guards - fix few checkpatch complaints (long lines, whitespaces, ...) The patch includes Makefile and .spec changes. I tested it compiles, make dist produces tarball with all headers, so does also the rpm. 'make' should automatically catch all changes in new headers and recompile dependent (=all) sources when any header changes. libcgroup.h - does not declare anything, it just includes all the other files. In future, it might contain base of doxygen documentation (some introduction etc.) libcgroup/error.h - the big enum with errors + error related functions libcgroup/init.h - libcgroup_init() and cgroup_get_subsys_mount_point() libcgroup/config.h - configuration reading/unloading libcgroup/groups.h - group manipulation stuff (create/modify/delete/free, incl. controllers and get/set values) + definition of struct cgroup (=must be included by libcgroup/tasks.h, which needs it) libcgroup/iterators.h - various walks, *_begin/next/end libcgroup/tasks.h - task classification, incl. rules cache manipulation In addition, I probably removed some #includes, which are not needed now when looking for the minimal #include set to build the project. I also hope I did not miss any function declaration or macro... Signed-off-by: Jan Safranek <jsafrane@redhat.com> Signed-off-by: Dhaval Giani <dhaval.giani@gmail.com>