s3:loadparm: prevent infinite include nesting.
commita100a9c48d73df69851099e15253a65f2dbc9f65
authorMichael Adam <obnox@samba.org>
Mon, 27 Apr 2009 16:10:14 +0000 (27 18:10 +0200)
committerKarolin Seeger <kseeger@samba.org>
Wed, 6 May 2009 06:52:41 +0000 (6 08:52 +0200)
tree4a3f51b6fe4d60b9e770a120c9e0eede9e42c5e7
parent02368626a273368a3b731d2b413e90d91ed15c5c
s3:loadparm: prevent infinite include nesting.

This introduces a hard coded MAX_INCLUDE_DEPTH of 100.
When this is exceeded, handle_include (and hence lp_load) fails.

One could of course implement a more intelligent loop detection
in the include-tree, but this would require some restructuring
of the internal loadparm housekeeping. Maybe as a second improvement
step.

Michael
source/param/loadparm.c