mirror of
https://github.com/osmarks/ngircd.git
synced 2024-12-13 10:20:28 +00:00
Fix Validate_Args(): unused parameter "Idx" and "Req"
This patch fixes the following error message of GCC (tested with version 4.3.0) when not compiling ngIRCd in "strict RFC" mode: parse.c: In function "Validate_Args": parse.c:341: error: unused parameter "Idx" parse.c:341: error: unused parameter "Req"
This commit is contained in:
parent
5df56111c4
commit
e5cf73b9ee
@ -338,17 +338,22 @@ Validate_Command( UNUSED CONN_ID Idx, UNUSED REQUEST *Req, bool *Closed )
|
|||||||
|
|
||||||
|
|
||||||
static bool
|
static bool
|
||||||
|
#ifdef STRICT_RFC
|
||||||
Validate_Args(CONN_ID Idx, REQUEST *Req, bool *Closed)
|
Validate_Args(CONN_ID Idx, REQUEST *Req, bool *Closed)
|
||||||
|
#else
|
||||||
|
Validate_Args(UNUSED CONN_ID Idx, UNUSED REQUEST *Req, bool *Closed)
|
||||||
|
#endif
|
||||||
{
|
{
|
||||||
#ifdef STRICT_RFC
|
#ifdef STRICT_RFC
|
||||||
int i;
|
int i;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
assert( Idx >= 0 );
|
|
||||||
assert( Req != NULL );
|
|
||||||
*Closed = false;
|
*Closed = false;
|
||||||
|
|
||||||
#ifdef STRICT_RFC
|
#ifdef STRICT_RFC
|
||||||
|
assert( Idx >= 0 );
|
||||||
|
assert( Req != NULL );
|
||||||
|
|
||||||
/* CR and LF are never allowed in command parameters.
|
/* CR and LF are never allowed in command parameters.
|
||||||
* But since we do accept lines terminated only with CR or LF in
|
* But since we do accept lines terminated only with CR or LF in
|
||||||
* "non-RFC-compliant mode" (besides the correct CR+LF combination),
|
* "non-RFC-compliant mode" (besides the correct CR+LF combination),
|
||||||
|
Loading…
Reference in New Issue
Block a user