亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? config.c

?? Upnp開發(fā)包文件
?? C
字號:
/////////////////////////////////////////////////////////////////////////////// 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"#include <stdlib.h>#include <stdio.h>#include "ithread.h"#include "upnp.h"#include <stdarg.h>#ifdef DEBUG#include <string.h>#endif//Mutex to synchronize all the log file opeartions in the debug modeithread_mutex_t GlobalDebugMutex;//File handle for the error log fileFILE *ErrFileHnd = NULL;//File handle for the information log fileFILE *InfoFileHnd = NULL;//Name of the error fileconst char *errFileName = "IUpnpErrFile.txt";//Name of the info fileconst char *infoFileName = "IUpnpInfoFile.txt";/************************************************************************* Function : UpnpDisplayBanner											*																	* Parameters:														*	IN FILE *fd: file descriptor where the banner will be written*	IN char **lines: The buffer that will be written*	IN int size: Size of the buffer*	IN int starLength: This parameter provides the width of the banner*																	* Description:														*	This functions takes the buffer and writes the buffer in the file as *	per the requested banner											* Returns: void***************************************************************************/void UpnpDisplayBanner( IN FILE * fd,                        IN char **lines,                        IN int size,                        IN int starLength );/************************************************************************* Function : SetLogFileNames											*																	* Parameters:														*	IN const char* ErrFileName: name of the error file*	IN const char *InfoFileName: name of the information file*	IN int size: Size of the buffer*	IN int starLength: This parameter provides the width of the banner*																	* Description:														*	This functions takes the buffer and writes the buffer in the file as *	per the requested banner											* Returns: void***************************************************************************/voidSetLogFileNames( IN const char *ErrFileName,                 IN const char *InfoFileName ){    if( ErrFileName ) {        errFileName = ErrFileName;    }    if( InfoFileName ) {        infoFileName = InfoFileName;    }}/************************************************************************* Function : InitLog											*																	* Parameters:	void													*																	* Description:														*	This functions initializes the log files* Returns: int*	-1 : If fails*	UPNP_E_SUCCESS : if success***************************************************************************/intInitLog(  ){    ithread_mutex_init( &GlobalDebugMutex, NULL );    if( DEBUG_TARGET == 1 ) {        if( ( ErrFileHnd = fopen( errFileName, "a" ) ) == NULL )            return -1;        if( ( InfoFileHnd = fopen( infoFileName, "a" ) ) == NULL )            return -1;    }    return UPNP_E_SUCCESS;}/************************************************************************* Function : CloseLog											*																	* Parameters:	void													*																	* Description:														*	This functions closes the log files* Returns: void***************************************************************************/voidCloseLog(  ){    if( DEBUG_TARGET == 1 ) {        fflush( ErrFileHnd );        fflush( InfoFileHnd );        fclose( ErrFileHnd );        fclose( InfoFileHnd );    }    ithread_mutex_destroy( &GlobalDebugMutex );}/*************************************************************************** Function : UpnpPrintf											*																	* Parameters:														*	IN Dbg_Level DLevel: The level of the debug logging. It will decide *		whether debug statement will go to standard output, or any of the *		log files.*	IN Dbg_Module Module: debug will go in the name of this module*	IN char *DbgFileName: Name of the file from where debug statement is*							coming*	IN int DbgLineNo : Line number of the file from where debug statement is*							coming*	IN char * FmtStr, ...: Variable number of arguments that will go in the *			debug statement*																	* Description:														*	This functions prints the debug statement either on the startdard output*	or log file along with the information from where this debug statement *	is coming* Returns: void***************************************************************************/DBGONLY( void UpnpPrintf( IN Dbg_Level DLevel,                          IN Dbg_Module Module,                          IN char *DbgFileName,                          IN int DbgLineNo,                          IN char *FmtStr,                          ... ) {         va_list ArgList;         va_start( ArgList, FmtStr );         if( DEBUG_LEVEL < DLevel ) return; if( DEBUG_ALL == 0 ) {         switch ( Module ) {case SSDP:         if( DEBUG_SSDP == 1 ) break;         elsereturn; case SOAP:         if( DEBUG_SOAP == 1 ) break;         elsereturn; case GENA:         if( DEBUG_GENA == 1 ) break;         elsereturn; case TPOOL:         if( DEBUG_TPOOL == 1 ) break;         elsereturn; case MSERV:         if( DEBUG_MSERV == 1 ) break;         elsereturn; case DOM:         if( DEBUG_DOM == 1 ) break;         elsereturn; case HTTP:         if( DEBUG_HTTP == 1 ) break;         elsereturn; case API:         if( DEBUG_API == 1 ) break;         elsereturn; default:         return;}         }         ithread_mutex_lock( &GlobalDebugMutex ); if( DEBUG_TARGET == 0 ) {         if( DbgFileName ) {         UpnpDisplayFileAndLine( stdout, DbgFileName, DbgLineNo );}         vfprintf( stdout, FmtStr, ArgList ); fflush( stdout );}         else         {         if( DLevel == 0 ) {         if( DbgFileName ) {         UpnpDisplayFileAndLine( ErrFileHnd, DbgFileName, DbgLineNo );}         vfprintf( ErrFileHnd, FmtStr, ArgList ); fflush( ErrFileHnd );}         else         {         if( DbgFileName ) {         UpnpDisplayFileAndLine( InfoFileHnd, DbgFileName, DbgLineNo );}         vfprintf( InfoFileHnd, FmtStr, ArgList ); fflush( InfoFileHnd );}         }         va_end( ArgList ); ithread_mutex_unlock( &GlobalDebugMutex );} )/*************************************************************************** Function : GetDebugFile											*																	* Parameters:														*	IN Dbg_Level DLevel: The level of the debug logging. It will decide *		whether debug statement will go to standard output, or any of the *		log files.*	IN Dbg_Module Module: debug will go in the name of this module*																	* Description:*	This function checks if the module is turned on for debug *	and returns the file descriptor corresponding to the debug level* Returns: FILE **	NULL : if the module is turn off for debug *	else returns the right file descriptor***************************************************************************/    DBGONLY( FILE * GetDebugFile( Dbg_Level DLevel, Dbg_Module Module ) {             if( DEBUG_LEVEL < DLevel ) return NULL; if( DEBUG_ALL == 0 ) {             switch ( Module ) {case SSDP:             if( DEBUG_SSDP == 1 ) break;             elsereturn NULL; case SOAP:             if( DEBUG_SOAP == 1 ) break;             elsereturn NULL; case GENA:             if( DEBUG_GENA == 1 ) break;             elsereturn NULL; case TPOOL:             if( DEBUG_TPOOL == 1 ) break;             elsereturn NULL; case MSERV:             if( DEBUG_MSERV == 1 ) break;             elsereturn NULL; case DOM:             if( DEBUG_DOM == 1 ) break;             elsereturn NULL; case API:             if( DEBUG_API == 1 ) break;             elsereturn NULL; default:             return NULL;}             }             if( DEBUG_TARGET == 0 ) {             return stdout;}             else             {             if( DLevel == 0 ) {             return ErrFileHnd;}             else             {             return InfoFileHnd;}             }             } )/*************************************************************************** Function : UpnpDisplayFileAndLine											*																	* Parameters:														*	IN FILE *fd: File descriptor where line number and file name will be *			written *	IN char *DbgFileName: Name of the file  *	IN int DbgLineNo : Line number of the file*																	* Description:*	This function writes the file name and file number from where*		debug statement is coming to the log file* Returns: void***************************************************************************/    DBGONLY( void UpnpDisplayFileAndLine( IN FILE * fd,                                          IN char *DbgFileName,                                          IN int DbgLineNo ) {             int starlength = 66;             char *lines[2];             char FileAndLine[500]; lines[0] = "DEBUG"; if( DbgFileName ) {             sprintf( FileAndLine, "FILE: %s, LINE: %d", DbgFileName,                      DbgLineNo ); lines[1] = FileAndLine;}             UpnpDisplayBanner( fd, lines, 2, starlength ); fflush( fd );} )/************************************************************************* Function : UpnpDisplayBanner											*																	* Parameters:														*	IN FILE *fd: file descriptor where the banner will be written*	IN char **lines: The buffer that will be written*	IN int size: Size of the buffer*	IN int starLength: This parameter provides the width of the banner*																	* Description:														*	This functions takes the buffer and writes the buffer in the file as *	per the requested banner											* Returns: void***************************************************************************/    DBGONLY( void UpnpDisplayBanner( IN FILE * fd,                                     IN char **lines,                                     IN int size,                                     IN int starLength ) {             char *stars = ( char * )malloc( starLength + 1 );             char *line = NULL;             int leftMarginLength = starLength / 2 + 1;             int rightMarginLength = starLength / 2 + 1;             char *leftMargin = ( char * )malloc( leftMarginLength );             char *rightMargin = ( char * )malloc( rightMarginLength );             int i = 0;             int LineSize = 0;             char *currentLine = ( char * )malloc( starLength + 1 );             memset( stars, '*', starLength );             stars[starLength] = 0;             memset( leftMargin, 0, leftMarginLength );             memset( rightMargin, 0, rightMarginLength );             fprintf( fd, "\n%s\n", stars ); for( i = 0; i < size; i++ ) {             LineSize = strlen( lines[i] );             line = lines[i]; while( LineSize > ( starLength - 2 ) ) {             memcpy( currentLine, line, ( starLength - 2 ) );             currentLine[( starLength - 2 )] = 0;             fprintf( fd, "*%s*\n", currentLine );             LineSize -= ( starLength - 2 ); line += ( starLength - 2 );}             if( LineSize % 2 == 0 ) {             leftMarginLength = rightMarginLength =             ( ( starLength - 2 ) - LineSize ) / 2;}             else             {             leftMarginLength = ( ( starLength - 2 ) - LineSize ) / 2;             rightMarginLength =             ( ( starLength - 2 ) - LineSize ) / 2 + 1;}             memset( leftMargin, ' ', leftMarginLength );             memset( rightMargin, ' ', rightMarginLength );             leftMargin[leftMarginLength] = 0;             rightMargin[rightMarginLength] = 0;             fprintf( fd, "*%s%s%s*\n", leftMargin, line, rightMargin );}             fprintf( fd, "%s\n\n", stars );             free( leftMargin );             free( rightMargin ); free( stars ); free( currentLine );} )

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
极品美女销魂一区二区三区免费| 欧美猛男超大videosgay| 国产农村妇女毛片精品久久麻豆 | 波多野结衣中文字幕一区 | 成人小视频在线| 国产精品麻豆欧美日韩ww| www.一区二区| 亚洲精品视频免费观看| 欧美精品tushy高清| 美女精品自拍一二三四| 国产人伦精品一区二区| 99久久婷婷国产综合精品电影| 亚洲欧美日韩久久精品| 欧美性生活大片视频| 免费成人你懂的| 国产视频一区二区三区在线观看| 91免费观看视频| 日本在线不卡一区| 欧美激情一区三区| 欧美在线视频不卡| 另类人妖一区二区av| 欧美精品自拍偷拍| 国产免费久久精品| 91国偷自产一区二区三区观看 | 中文字幕精品一区| 在线观看日产精品| 国内精品写真在线观看| 中文字幕亚洲综合久久菠萝蜜| 777色狠狠一区二区三区| 国产麻豆91精品| 亚洲成人动漫在线观看| 久久天堂av综合合色蜜桃网| 日本久久一区二区| 国内成人精品2018免费看| 成人欧美一区二区三区1314| 9191精品国产综合久久久久久| 丁香婷婷深情五月亚洲| 偷拍日韩校园综合在线| 国产精品久久久久久亚洲伦| 91精品国产免费| 色综合一区二区| 久久精品久久综合| 日韩视频123| 久久一二三国产| 久久精品男人的天堂| 国产电影一区二区三区| 亚欧色一区w666天堂| 综合激情成人伊人| 欧美精品一区二区三区蜜桃| 欧美自拍丝袜亚洲| 成人精品在线视频观看| 蜜桃久久久久久| 亚洲福利视频一区| 亚洲乱码国产乱码精品精的特点| 亚洲精品一线二线三线| 9191成人精品久久| 欧美色大人视频| 99热在这里有精品免费| 国产精品1区二区.| 久久99精品国产.久久久久久| 亚洲影视在线观看| 中文字幕综合网| 欧美国产日本韩| 亚洲精品在线观看网站| 国产欧美日韩视频一区二区| 国内成人精品2018免费看| 一区二区三区在线影院| 1区2区3区精品视频| 国产欧美日韩激情| 日本一区二区三区四区在线视频| 日韩三级在线免费观看| 欧美老人xxxx18| 在线免费观看不卡av| 95精品视频在线| 91麻豆国产在线观看| 91蝌蚪porny| 99久久99久久免费精品蜜臀| 成人91在线观看| av毛片久久久久**hd| 成人精品gif动图一区| 成人午夜精品一区二区三区| 国产91在线|亚洲| 成人国产免费视频| av一区二区三区四区| 91一区二区在线观看| 色综合天天在线| 日本道精品一区二区三区| 欧美性视频一区二区三区| 欧美影片第一页| 欧美精选在线播放| 欧美一级免费观看| 欧美videofree性高清杂交| 精品日产卡一卡二卡麻豆| 欧美mv日韩mv国产网站| 久久色视频免费观看| 国产清纯美女被跳蛋高潮一区二区久久w| 久久久精品tv| 亚洲色图丝袜美腿| 亚洲成人第一页| 美女任你摸久久| 91麻豆精东视频| 欧洲一区在线观看| 欧美一区二区三区人| 久久婷婷国产综合精品青草| 中文字幕亚洲一区二区av在线| 亚洲精品成a人| 男人的j进女人的j一区| 国产成人自拍高清视频在线免费播放| 丁香啪啪综合成人亚洲小说| 色婷婷亚洲综合| 91精品中文字幕一区二区三区| 日韩一区二区三区观看| 国产精品全国免费观看高清| 亚洲成人激情av| 国产精华液一区二区三区| 色网综合在线观看| 日韩午夜激情电影| 国产精品国产自产拍高清av | 欧美午夜理伦三级在线观看| 欧美一区二区三区日韩视频| 国产精品女上位| 日日摸夜夜添夜夜添精品视频| 国产精品1024| 777精品伊人久久久久大香线蕉| 国产亚洲精品久| 午夜精品久久久久影视| 国产激情91久久精品导航| 欧美图区在线视频| 欧美国产丝袜视频| 久久黄色级2电影| 一本大道久久a久久精二百| 欧美大胆人体bbbb| 一区二区三区四区乱视频| 国产乱码字幕精品高清av| 欧美日韩中文另类| 国产精品女主播在线观看| 蜜桃视频在线观看一区二区| 91美女在线视频| 欧美激情一区二区三区蜜桃视频| 日韩成人免费电影| 91同城在线观看| 久久免费午夜影院| 日韩av在线发布| 91国产成人在线| 中文字幕一区二区三区在线观看| 蜜桃久久av一区| 欧美福利电影网| 亚洲一区视频在线| av一本久道久久综合久久鬼色| 日韩精品一区二区三区四区视频 | 午夜精品国产更新| 91麻豆蜜桃一区二区三区| 久久女同性恋中文字幕| 日韩激情一二三区| 欧美男女性生活在线直播观看| 亚洲精品网站在线观看| 成人av在线一区二区| 国产女主播一区| 国产福利91精品| 久久久久一区二区三区四区| 麻豆国产精品一区二区三区| 欧美精品丝袜久久久中文字幕| 亚洲激情校园春色| 在线亚洲一区二区| 一区二区三区在线影院| 97久久精品人人爽人人爽蜜臀| 国产精品全国免费观看高清| 国产99久久久精品| 欧美激情中文字幕| 成人午夜精品在线| 国产精品高潮呻吟| 99re66热这里只有精品3直播| 亚洲欧美一区二区视频| 99re8在线精品视频免费播放| 最新中文字幕一区二区三区| 菠萝蜜视频在线观看一区| 国产精品久久一级| 99精品桃花视频在线观看| 亚洲日本在线视频观看| 色爱区综合激月婷婷| 亚洲综合偷拍欧美一区色| 欧美日韩中文另类| 男男成人高潮片免费网站| 精品久久免费看| 成人性生交大合| 亚洲欧美国产高清| 欧美日韩一区二区三区在线看 | 日韩一区和二区| 久久国产精品色婷婷| 久久久久久久精| 91在线一区二区三区| 亚洲精品免费一二三区| 欧美日韩国产首页在线观看| 日本成人中文字幕| 国产亚洲一二三区| 色综合久久久久久久久久久| 视频一区二区三区中文字幕| 精品处破学生在线二十三| 波多野结衣中文一区| 亚洲h动漫在线|