comparison fuzz-common.c @ 1558:2f64cb3d3007 fuzz

- #if not #ifdef for DROPBEAR_FUZZ - fix some unused variables
author Matt Johnston <matt@ucc.asn.au>
date Wed, 28 Feb 2018 21:40:08 +0800
parents 66a1a2547133
children 92c93b4a3646
comparison
equal deleted inserted replaced
1557:61a793b6e471 1558:2f64cb3d3007
40 fuzz_seed(); 40 fuzz_seed();
41 41
42 return DROPBEAR_SUCCESS; 42 return DROPBEAR_SUCCESS;
43 } 43 }
44 44
45 #if DEBUG_TRACE
45 static void fuzz_dropbear_log(int UNUSED(priority), const char* format, va_list param) { 46 static void fuzz_dropbear_log(int UNUSED(priority), const char* format, va_list param) {
46
47 char printbuf[1024];
48
49 #if DEBUG_TRACE
50 if (debug_trace) { 47 if (debug_trace) {
48 char printbuf[1024];
51 vsnprintf(printbuf, sizeof(printbuf), format, param); 49 vsnprintf(printbuf, sizeof(printbuf), format, param);
52 fprintf(stderr, "%s\n", printbuf); 50 fprintf(stderr, "%s\n", printbuf);
53 } 51 }
54 #endif
55 } 52 }
53 #else
54 static void fuzz_dropbear_log(int UNUSED(priority), const char* UNUSED(format), va_list UNUSED(param)) {
55 /* No print */
56 }
57 #endif /* DEBUG_TRACE */
56 58
57 void fuzz_svr_setup(void) { 59 void fuzz_svr_setup(void) {
58 struct passwd *pw;
59
60 fuzz_common_setup(); 60 fuzz_common_setup();
61 61
62 _dropbear_exit = svr_dropbear_exit; 62 _dropbear_exit = svr_dropbear_exit;
63 63
64 char *argv[] = { 64 char *argv[] = {