Backport of svn revision 493: Declare a few functions to have proper

(void) argument list.

	* SF Patch Tracker [ 2857611 ] Declare a few functions to have proper
	(void) argument list.
	Submitted By: zephyrus ( zephyrus00jp )
	
	In a publicly installed headers, a few functions are declared without any
	arguments at all, a la "()".
	When I used gcc's -Wimplict and -Wstrict-prototypes to check for the
	mismatch of
	function prototype declarations and their usage in my own program,
	some headers from libupnp-1.6.6 produced warnings.

	They are not strictly bugs, but pretty much annoying. This is 2009, and
	almost all the important compilers
	understand ISO-C.

	So the offending functions are declared as "(void") to show that they have
	no arguments at all.



git-svn-id: https://pupnp.svn.sourceforge.net/svnroot/pupnp/branches/branch-1.6.x@494 119443c7-1b9e-41f8-b6fc-b9c35fce742c
This commit is contained in:
Marcelo Roberto Jimenez
2010-03-15 15:34:54 +00:00
parent 4ad6ea3545
commit a1d707ac81
7 changed files with 131 additions and 112 deletions

View File

@@ -1,33 +1,33 @@
///////////////////////////////////////////////////////////////////////////
//
// Copyright (c) 2000-2003 Intel Corporation
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are met:
//
// * Redistributions of source code must retain the above copyright notice,
// this list of conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above copyright notice,
// this list of conditions and the following disclaimer in the documentation
// and/or other materials provided with the distribution.
// * Neither name of Intel Corporation nor the names of its contributors
// may be used to endorse or promote products derived from this software
// without specific prior written permission.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL INTEL OR
// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
// EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
// PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
// OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
//
///////////////////////////////////////////////////////////////////////////
/*******************************************************************************
*
* Copyright (c) 2000-2003 Intel Corporation
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* - Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
* - Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
* - Neither name of Intel Corporation nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL INTEL OR
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
* OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
******************************************************************************/
#include "config.h"
@@ -396,7 +396,7 @@ PrintThreadPoolStats(
* UPNP_E_SUCCESS on success, nonzero on failure.
*****************************************************************************/
int
UpnpFinish()
UpnpFinish(void)
{
#ifdef INCLUDE_DEVICE_APIS
UpnpDevice_Handle device_handle;
@@ -487,7 +487,7 @@ UpnpFinish()
* local port on success, zero on failure.
*****************************************************************************/
unsigned short
UpnpGetServerPort( void )
UpnpGetServerPort(void)
{
if( UpnpSdkInit != 1 )
@@ -508,7 +508,7 @@ UpnpGetServerPort( void )
* return the IP address string on success else NULL of failure
***************************************************************************/
char *
UpnpGetServerIpAddress( void )
UpnpGetServerIpAddress(void)
{
if( UpnpSdkInit != 1 )
@@ -3880,7 +3880,7 @@ UpnpRemoveVirtualDir( IN const char *dirName )
*
***************************************************************************/
void
UpnpRemoveAllVirtualDirs()
UpnpRemoveAllVirtualDirs(void)
{
virtualDirList *pCur;
@@ -3961,7 +3961,7 @@ UpnpEnableWebserver( IN int enable )
* 0, if webserver disabled
***************************************************************************/
int
UpnpIsWebserverEnabled()
UpnpIsWebserverEnabled(void)
{
if( UpnpSdkInit != 1 ) {
return 0;
@@ -4076,9 +4076,9 @@ UpnpSetContentLength( IN UpnpClient_Handle Hnd,
***************************************************************************/
int
UpnpSetMaxContentLength (
IN size_t contentLength
/** Permissible content length, in bytes */
)
IN size_t contentLength
/** Permissible content length, in bytes */
)
{
int errCode = UPNP_E_SUCCESS;
@@ -4096,4 +4096,3 @@ UpnpSetMaxContentLength (
}
/*********************** END OF FILE upnpapi.c :) ************************/