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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? wcegprs.cpp

?? Open DMT Client C Source code
?? CPP
?? 第 1 頁 / 共 2 頁
字號:
    }    return rtn;}// ----------------------------------------------------------------------------/* make sure a connection has been established */static utBool _wceGprsConnect(HRASCONN *pRasConn){    const char *entryName = propGetString(PROP_COMM_CONNECTION, DEFAULT_ENTRY_NAME);    if (pRasConn) { *pRasConn = NULL; }    /* already connected? */    HRASCONN hExistingRasConn = wceGprsGetConnection(entryName);    if (wceGprsIsConnected(hExistingRasConn)) {        logDEBUG(LOGSRC,"GPRS already connected: %s", entryName);        _wceResetTimerLong  = 0L;        _wceResetTimerShort = 0L;        if (pRasConn) { *pRasConn = hExistingRasConn; }        return utTrue;    }    //logDEBUG(LOGSRC,"GPRS attempt connection: %s", entryName);    /* signal strength */    // check signal strength here    /* RASDIALPARAMS structure */    RASDIALPARAMS rasDialParms;    memset(&rasDialParms, 0, sizeof(rasDialParms));    rasDialParms.dwSize = sizeof(rasDialParms);    strWideCopy(rasDialParms.szEntryName, RAS_MaxEntryName, entryName, -1);    /* init RAS configuration from system parameters */    BOOL hasRasParams = FALSE;    BOOL inclPass = FALSE;	DWORD rasEntryErr = RasGetEntryDialParams(NULL, &rasDialParms, &inclPass);    if (rasEntryErr) {        // Possible errors:        //  1168  ERROR_NOT_FOUND   Element not found        logERROR(LOGSRC,"No dial params [%ld]: %ls", rasEntryErr, rasDialParms.szEntryName);        //return utFalse;    } else {        hasRasParams = TRUE;    }    //logINFO(LOGSRC,"S) inclPass : %d\n" , inclPass);    /* override parameters */    // szPhoneNumber    const char *phoneNum = propGetString(PROP_COMM_APN_PHONE, "");    if (phoneNum && *phoneNum) {        strWideCopy(rasDialParms.szPhoneNumber, RAS_MaxPhoneNumber, phoneNum, -1);        hasRasParams = TRUE;    }    // szCallbackNumber    const char *callback = "";    if (callback && *callback) {        strWideCopy(rasDialParms.szCallbackNumber, RAS_MaxCallbackNumber, callback, -1);        hasRasParams = TRUE;    }    // szUserName    const char *apnUser = propGetString(PROP_COMM_APN_USER,"");    if (apnUser && *apnUser) {        strWideCopy(rasDialParms.szUserName, UNLEN, apnUser, -1);        hasRasParams = TRUE;    }    // szPassword    const char *apnPass = propGetString(PROP_COMM_APN_PASSWORD,"");    if (apnPass && *apnPass) {        strWideCopy(rasDialParms.szPassword, PWLEN, apnPass, -1);        hasRasParams = TRUE;    }    // szDomain    const char *apnDomain = propGetString(PROP_COMM_APN_SERVER,"");    if (apnDomain && *apnDomain) {        strWideCopy(rasDialParms.szDomain, DNLEN, apnDomain, -1);        hasRasParams = TRUE;    }        /* do we have any dialing parameters? */    if (!hasRasParams) {        logERROR(LOGSRC,"No RAS dialing parameters!");        return utFalse;    }    /* Dial/Connect */#if defined(WCEGPRS_CONNECT_VIA_RASDIAL_EXE)    // External RASDIAL connection here (if implemented)#else    // "RasDial(...)" appears to have its share of problems:    // - On several occasions, 'RasDial' has caused the program to terminate.    // - On at least one occasion, a call to 'RasDial' never returned.  I suspect    //   that it had terminated the current thread.    // - 'RasDial' may get in an endless 'ERROR_PORT_DISCONNECTED' error loop even    //   though a valid SIM card is in place and GPRS coverage is fine.  (I've been    //   able to recover in this situation by hard-resetting the phone).    /* call 'RasDial(...)' */    // In marginal GPRS coverage, this call can hang for more than 60 seconds     // before returning a failed connection attempt.    UInt32 rasDialStartTime = utcGetTimeSec();    logDEBUG(LOGSRC,"[%lu] 'RasDial' start ...", rasDialStartTime);    HRASCONN hRasConn = NULL;    DWORD rasDialErr = RasDial(NULL,NULL,&rasDialParms,NULL,NULL,&hRasConn);    UInt32 rasDialEndTime = utcGetTimeSec();    logDEBUG(LOGSRC,"[%lu] 'RasDial' end ... [%ld sec]", rasDialEndTime, (rasDialEndTime - rasDialStartTime));    if (pRasConn) { *pRasConn = hRasConn; }        /* check returned errors */	if (rasDialErr != SUCCESS) {        // Errors encountered (see 'raserror.h' for a complete list)        // 604  ERROR_WRONG_INFO_SPECIFIED  [may be sent when GPRS is unavailable]        // 608  ERROR_DEVICE_DOES_NOT_EXIST [likely an invalid entry name]        // 619  ERROR_PORT_DISCONNECTED     [may already be connected]        // 631  ERROR_USER_DISCONNECTION        // 633  ERROR_PORT_NOT_AVAILABLE        // 660  ERROR_NO_RESPONSES        // 679  ERROR_NO_CARRIER        // ---------------------------------                /* hang-up */        if (hRasConn) {            wceGprsDisconnect(hRasConn);        } else {            // wait here even if 'RasDial' failed and 'hRasConn' is null            threadSleepMS(3500L);        }                /* check specific error */        if (rasDialErr == ERROR_WRONG_INFO_SPECIFIED) {            // - I've seen this error occur when either GPRS is unavailable, or the            // phone is turned off.  For now, just continue with the retry ...        } else        if (rasDialErr == ERROR_PORT_DISCONNECTED) {            // - This most likely indicates that GPRS coverage is not available.            // - When this error occurs multiple times and GPRS *IS* available, I've been             //   able to recover by manually turning off the phone connection, then turning             //   it back on (while testing on an HP hw6945).  In an attempt to perform this             //   reset automatically, we'll try to detect this state and attempt to hang-up             //   the connection, hopefully clearing this error state on the next iteration.            //   This will not be effective if GPRS coverage is not available.            // - This error may also occur if the SIM card is not installed, in which            //   case this error will continue forever.            logERROR(LOGSRC,"RasDial ERROR_PORT_DISCONNECTED [%ld]", (Int32)rasDialErr);        } else        if (rasDialErr == ERROR_PORT_NOT_AVAILABLE) {            // - This likely indicates that the phone/modem is locked up and unusable.            // - Or we may actually be connected, but under a different entry-name.            // - This error can also occur if the SIM card is not installed, in which            //   case this error will continue forever.            logERROR(LOGSRC,"RasDial ERROR_PORT_NOT_AVAILABLE [%ld]", (Int32)rasDialErr);        } else        if (rasDialErr == ERROR_DEVICE_DOES_NOT_EXIST) {            // - This likely indicates an invalid entry name            logERROR(LOGSRC,"RasDial ERROR_DEVICE_DOES_NOT_EXIST [%ld] - %s", (Int32)rasDialErr, entryName);            wceGprsListEntryNames(); // displa entry names         } else {            logINFO(LOGSRC,"RasDial connection failed [raserr=%ld]", (Int32)rasDialErr);        }                /* short timeout */        // Short timeouts specifically checks for ERROR_PORT_NOT_AVAILABLE errors.        // 'ERROR_PORT_NOT_AVAILABLE' errors may not be recoverable.        if (rasDialErr == ERROR_PORT_NOT_AVAILABLE) {            // we may not be able to recover without a rebbot, set a short timer            if (_wceResetTimerShort == 0L) {                // default reset timer, short delay                _wceResetTimerShort = utcGetTimer();            }        } else {            // we may be able to recover from non-port-not-available errors            _wceResetTimerShort = 0L;        }        /* long timeout */        // Long timeouts check for no connectivity, for any reason, for a long period of time.        if (_wceResetTimerLong == 0L) {            // default reset timer, long delay            _wceResetTimerLong = utcGetTimer();        }        /* check timeouts */        if ((MODEM_LONG_RESET_TIMEOUT > 0L) && (_wceResetTimerLong > 0L) &&             utcIsTimerExpired(_wceResetTimerLong,MODEM_LONG_RESET_TIMEOUT)) {            // we've been trying unsuccessfully for awhile now, just reset the modem            _wceResetTimerLong  = utcGetTimer();            _wceResetTimerShort = 0L;            wceGprsResetModem();            // (if we've rebooted, control should not reach here)        } else        if ((MODEM_SHORT_RESET_TIMEOUT > 0L) && (_wceResetTimerShort > 0L) &&             utcIsTimerExpired(_wceResetTimerShort,MODEM_SHORT_RESET_TIMEOUT)) {            // we've been trying unsuccessfully for awhile now, just reset the modem            _wceResetTimerLong  = utcGetTimer();            _wceResetTimerShort = 0L;            wceGprsResetModem();            // (if we've rebooted, control should not reach here)        }        /* 'continue' attempt */        // after a few minutes, start indicating that we've made a connection        // (the protocol transport will fail if it cannot actually transmit)        // we do this just-in-case this error is incorrect, which may in fact         // be the case if we are connected using a different "Connection name".        if (utcIsTimerExpired(_wceResetTimerLong,MODEM_CONTINUE_TIMEOUT)) {            logERROR(LOGSRC,"Continuing as if connected ...");            return utTrue;        }        /* connection failed */        return utFalse;    }    #endif // else defined(WCEGPRS_CONNECT_VIA_RASDIAL_EXE)    /* connected! */    logINFO(LOGSRC,"------- GPRS Connection Success ------");    _wceResetTimerLong  = 0L;    _wceResetTimerShort = 0L;    threadSleepMS(2000L);    return utTrue;}/* make sure a connection has been established */utBool wceGprsConnect(HRASCONN *pRasConn, utBool disconnectFirst){    utBool rtn = utFalse;    /* force a disconnect first? */    if (disconnectFirst && pRasConn) {        // This usually indicates that the caller was unable to establish a socket         // connection during the last GPRS connection.  Disconnect the previous         // failing connection before establishing a new connection.  In this         // situation, it is possible that if enough time has passed since the last        // socket-connection attempt, the OS may have already closed the old failing        // GPRS-connection and established a new one.  In which case we may be closing         // a good GPRS-connection.  There's no easy way to determine if the OS has        // in fact already established a connection, so going ahead and closing the        // current GPRS-connection, and establishing a new connection is the safest        // thing to do at this point.        logINFO(LOGSRC,"Forcing a disconnect before establishing a new connection");        wceGprsDisconnect(*pRasConn);    }    /* connect (may use an existing connection, if available) */    // This can take up to 60 seconds in a marginal GPRS coverage area.    rtn = _wceGprsConnect(pRasConn);        return rtn;}// ----------------------------------------------------------------------------#endif // defined(TARGET_WINCE)

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产在线精品一区二区不卡了| 欧美日韩aaa| 91精品国产乱| 国产喷白浆一区二区三区| 亚洲福利视频导航| av不卡免费电影| 亚洲精品一区二区三区99| 亚洲一二三区不卡| 成人激情电影免费在线观看| 日韩一级片在线播放| 亚洲精品成人悠悠色影视| 粉嫩嫩av羞羞动漫久久久| 欧美三级中文字幕在线观看| 国产精品国产a| 国产一区二三区好的| 日韩一区二区在线播放| 亚洲在线视频网站| 不卡的av电影| 国产精品天干天干在线综合| 精品视频999| 国产精品护士白丝一区av| 九九国产精品视频| 欧美一区二区三区视频免费播放| 一区二区三区波多野结衣在线观看| 成人永久看片免费视频天堂| 久久久亚洲精品一区二区三区| 美女视频黄免费的久久| 777精品伊人久久久久大香线蕉| 亚洲黄色小视频| 99精品国产一区二区三区不卡| 国产欧美日韩综合精品一区二区| 国产精品自拍一区| 国产亚洲欧美一区在线观看| 国产真实乱子伦精品视频| 欧美mv日韩mv国产网站| 秋霞午夜av一区二区三区| 7777精品伊人久久久大香线蕉超级流畅| 亚洲精品国产视频| 欧美视频在线一区二区三区 | 日本中文字幕一区二区有限公司| 欧美亚洲动漫另类| 亚洲电影激情视频网站| 在线成人免费视频| 日本不卡不码高清免费观看| 欧美一级专区免费大片| 精品一区二区三区在线观看| xfplay精品久久| 岛国一区二区在线观看| 国产精品色呦呦| 91日韩一区二区三区| 亚洲国产一区二区在线播放| 欧美人xxxx| 国模少妇一区二区三区| 国产午夜久久久久| 91色在线porny| 五月婷婷色综合| 久久综合九色综合欧美亚洲| 成人性生交大片免费看视频在线 | 91精品国产麻豆国产自产在线| 秋霞成人午夜伦在线观看| 久久夜色精品国产欧美乱极品| 成人免费看黄yyy456| 亚洲午夜免费电影| 久久综合久久综合亚洲| 91热门视频在线观看| 欧美a级一区二区| 国产精品日韩成人| 91精品国产欧美一区二区成人| 国产一区二区在线电影| 老司机午夜精品99久久| 国产精品久久久久精k8| 91精品国产91久久综合桃花| 国产精品 日产精品 欧美精品| 夜夜精品视频一区二区| 国产亚洲一区二区三区| 欧美日韩国产美| 成人av集中营| 久久精品国产在热久久| 一区二区三区四区视频精品免费 | 欧美精品九九99久久| 风间由美中文字幕在线看视频国产欧美| 亚洲永久精品大片| 国产欧美精品一区二区三区四区 | 欧美aaaaaa午夜精品| 一区在线中文字幕| 日韩美女一区二区三区四区| 色婷婷亚洲综合| 国产福利一区在线观看| 日本在线播放一区二区三区| 国产一区在线观看麻豆| 亚洲福利视频三区| 日韩理论片网站| 国产女主播一区| 欧美精品一区二区在线观看| 欧美日韩精品欧美日韩精品一 | 国产精品毛片高清在线完整版| 日韩一级视频免费观看在线| 欧美亚一区二区| 成人a免费在线看| 黄一区二区三区| 三级在线观看一区二区| 亚洲主播在线观看| 亚洲精品乱码久久久久久日本蜜臀| 久久婷婷色综合| 在线成人av网站| 欧洲日韩一区二区三区| 色综合久久88色综合天天 | 日本不卡一区二区三区| 亚洲美女偷拍久久| ㊣最新国产の精品bt伙计久久| 久久久久久久国产精品影院| 亚洲精品一区在线观看| 日韩免费看的电影| 欧美电影影音先锋| 欧美日韩不卡一区| 777午夜精品视频在线播放| 欧美日韩国产a| 欧美三级一区二区| 在线观看www91| 91国产成人在线| 欧美日韩亚洲不卡| 欧美日韩精品一区二区三区| 欧美电影一区二区三区| 91精品国产91久久综合桃花| 日韩视频免费观看高清完整版 | 国产欧美日韩在线视频| 中文一区二区在线观看| 日韩理论片在线| 亚洲电影一区二区三区| 青青青爽久久午夜综合久久午夜| 视频在线观看91| 乱中年女人伦av一区二区| 国产美女av一区二区三区| 成人av免费在线播放| 在线观看不卡一区| 欧美一二三在线| 国产无人区一区二区三区| 国产精品素人视频| 一区二区三区四区在线播放| 日韩电影网1区2区| 国产毛片精品一区| 色狠狠一区二区三区香蕉| 91精品国产91综合久久蜜臀| 久久久精品影视| 一区二区三区在线免费| 久久精品国产精品亚洲精品| 顶级嫩模精品视频在线看| 99国产精品国产精品久久| 在线播放欧美女士性生活| 久久亚洲综合色| 亚洲综合自拍偷拍| 精品在线视频一区| 成人免费不卡视频| 7878成人国产在线观看| 日本一区二区成人在线| 亚洲成人动漫av| 成人午夜短视频| 欧美高清dvd| 中文字幕欧美激情一区| 日韩精品亚洲专区| 99在线热播精品免费| 日韩一区二区视频| 亚洲欧美aⅴ...| 久久成人麻豆午夜电影| 一本大道久久a久久综合| 精品精品国产高清a毛片牛牛 | 在线观看一区日韩| 国产亚洲一区二区在线观看| 午夜精品一区二区三区三上悠亚| 国产一区二区精品久久| 欧美丰满嫩嫩电影| 亚洲欧洲在线观看av| 国产精品综合二区| 日韩欧美中文字幕一区| 亚洲精品乱码久久久久久日本蜜臀| 韩国午夜理伦三级不卡影院| 欧美综合一区二区| 欧美激情一区不卡| 久久99精品国产麻豆婷婷| 欧美日韩第一区日日骚| 亚洲男同1069视频| 成人免费视频一区二区| 久久久电影一区二区三区| 免费不卡在线观看| 欧美日韩国产首页| 一区二区三区四区不卡在线| 成人丝袜视频网| 国产精品欧美极品| 岛国精品在线观看| 欧美国产日韩亚洲一区| 国产另类ts人妖一区二区| 欧美mv日韩mv| 激情综合五月婷婷| 日韩精品一区二| 久久97超碰色| 久久久久国产一区二区三区四区| 美女视频黄 久久| 欧美大片在线观看一区二区| 久久精品国内一区二区三区| 日韩视频免费直播|