aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--src/tru/tinyradutil.c17
-rw-r--r--src/tru/tinyradutil.h7
2 files changed, 24 insertions, 0 deletions
diff --git a/src/tru/tinyradutil.c b/src/tru/tinyradutil.c
index 05f3b89..edbc996 100644
--- a/src/tru/tinyradutil.c
+++ b/src/tru/tinyradutil.c
@@ -294,6 +294,23 @@ tru_printf(
294} 294}
295 295
296 296
297int
298tru_verbose(
299 TinyRadUtilConf * cnf,
300 const char * fmt,
301 ... )
302{
303 int rc;
304 va_list args;
305 if (!(cnf->opts & TRUTILS_OPT_VERBOSE))
306 return(0);
307 va_start(args, fmt);
308 rc = vprintf(fmt, args);
309 va_end(args);
310 return(rc);
311}
312
313
297//-------------------------// 314//-------------------------//
298// miscellaneous functions // 315// miscellaneous functions //
299//-------------------------// 316//-------------------------//
diff --git a/src/tru/tinyradutil.h b/src/tru/tinyradutil.h
index 9fbaf8d..641d304 100644
--- a/src/tru/tinyradutil.h
+++ b/src/tru/tinyradutil.h
@@ -201,6 +201,13 @@ tru_printf(
201 ... ); 201 ... );
202 202
203 203
204int
205tru_verbose(
206 TinyRadUtilConf * cnf,
207 const char * fmt,
208 ... );
209
210
204//--------------------------// 211//--------------------------//
205// miscellaneous prototypes // 212// miscellaneous prototypes //
206//--------------------------// 213//--------------------------//