[PATCH] Extending the debugging system with per-class logfiles

Jeremy Allison jra at samba.org
Mon Dec 17 22:14:40 UTC 2018

On Mon, Dec 17, 2018 at 05:15:17PM +0100, Ralph Böhme via samba-technical wrote:
> On Wed, Dec 12, 2018 at 11:04:50PM +0100, Ralph Böhme via samba-technical wrote:
> On Mon, Dec 10, 2018 at 04:26:27PM +0100, Ralph Böhme via samba-technical wrote:
> > ok, this version seems to pass CI. If anyone has the time, please take a
> > look. The more eyes the better, this is a core infrastructure piece and
> > I don't wanna screw it. :)
> > 
> > CI of older version, minimal changes since then:
> > https://gitlab.com/samba-team/devel/samba/pipelines/39906963
> > 
> > CI attached patchset:
> > https://gitlab.com/samba-team/devel/samba/pipelines/39941794
> latest version attached with some patch reordering and some minor changes.
> CI: https://gitlab.com/samba-team/devel/samba/pipelines/40028064
> Please review & push if happy. Thanks!

Wow - fantastic work !

Only one change I'd request (same one in several patches):


[PATCH 13/17] debug: update need_to_check_log_size() for per debug-class logfiles

You have:

+       int i;
+       for (i = DBGC_ALL + 1; i < debug_num_classes; i++) {

As debug_num_classes is defined as size_t, then i should
also be size_t.

This is the same in:

[PATCH 14/17] debug: update logsize checking for per debug-class logfiles
[PATCH 16/17] debug: enable per debug-class logfiles

And in

[PATCH 15/17] debug: remove fd and debugf from state, use  dbgc_config[DBGC_ALL]

there's an existing 'int i;' that probably needs changing
to size_t (you might want to do a pass over the file
looking for for() loops against debug_num_classes
and make sure all the iterator variables are size_t
at least, or 'unsigned' and add that as an additional

With those changes, RB+ Jeremy Allison.

Great work Ralph ! Let me know if you can do those
changes or you want me to do them.



More information about the samba-technical mailing list