Close ports when there is a fatal error allowing OS to free all handles to it. Do not report OSErrors on sending messages as these are confusing.
--- a/connectivity/com.nokia.tcf/native/TCFNative/TCFClient/TCAPIConnectionJni.cpp Tue Jun 15 10:21:51 2010 -0500
+++ b/connectivity/com.nokia.tcf/native/TCFNative/TCFClient/TCAPIConnectionJni.cpp Tue Jun 15 16:19:30 2010 -0500
@@ -1326,11 +1326,11 @@
TCDEBUGLOGA3("nativeSendMessage return ret=%d, osError=%d : %s\n", ret, osError, GetErrorText(osError));
TCDEBUGCLOSE();
- if (ret == TCAPI_ERR_COMM_ERROR && osError > 0)
- {
- jclass clazz = env->FindClass("Ljava/lang/Exception;");
- env->ThrowNew(clazz, GetErrorText(osError));
- }
+// if (ret == TCAPI_ERR_COMM_ERROR && osError > 0)
+// {
+// jclass clazz = env->FindClass("Ljava/lang/Exception;");
+// env->ThrowNew(clazz, GetErrorText(osError));
+// }
return ret;
}
--- a/connectivity/com.nokia.tcf/native/TCFNative/TCFClient/TCFClient.plg Tue Jun 15 10:21:51 2010 -0500
+++ b/connectivity/com.nokia.tcf/native/TCFNative/TCFClient/TCFClient.plg Tue Jun 15 16:19:30 2010 -0500
@@ -3,117 +3,72 @@
<pre>
<h1>Build Log</h1>
<h3>
---------------------Configuration: TCFCommSerial - Win32 Release--------------------
+--------------------Configuration: TCFClient - Win32 Release--------------------
</h3>
<h3>Command Lines</h3>
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP60C.tmp" with contents
+Creating command line "rc.exe /l 0x409 /fo"Release/resource.res" /d "NDEBUG" "C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFClient\resource.rc""
+Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP91E.tmp" with contents
[
-/nologo /Zp2 /MT /W3 /GX /O2 /I "..\TCFServer" /I "..\Common\Headers" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TCFCOMMSERIAL_EXPORTS" /Fp"Release/TCFCommSerial.pch" /Yu"stdafx.h" /Fo"Release/" /Fd"Release/" /FD /c
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\BaseCom.cpp"
+/nologo /Zp2 /MT /W3 /GX /O2 /I "..\Common\Headers" /I ".\jdk1.5.0_10\include" /I ".\jdk1.5.0_10\include\win32" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TCFCLIENT_EXPORTS" /Fp"Release/TCFClient.pch" /Yu"stdafx.h" /Fo"Release/" /Fd"Release/" /FD /c
+"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFClient\ClientManager.cpp"
+"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\ErrorMonitorData.cpp"
+"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\InputStream.cpp"
"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\mutex.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommSerial\RealSerialComm.cpp"
+"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\ServerClient.cpp"
+"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\shareddata.cpp"
+"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFClient\TCAPIConnectionJni.cpp"
"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\TCDebugLog.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommSerial\TCFCommSerial.cpp"
+"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFClient\TCFClient.cpp"
+"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFClient\TCFCppApi.cpp"
]
-Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP60C.tmp"
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP60D.tmp" with contents
+Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP91E.tmp"
+Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP91F.tmp" with contents
[
-/nologo /Zp2 /MT /W3 /GX /O2 /I "..\TCFServer" /I "..\Common\Headers" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TCFCOMMSERIAL_EXPORTS" /Fp"Release/TCFCommSerial.pch" /Yc"stdafx.h" /Fo"Release/" /Fd"Release/" /FD /c
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommSerial\StdAfx.cpp"
+/nologo /Zp2 /MT /W3 /GX /O2 /I "..\Common\Headers" /I ".\jdk1.5.0_10\include" /I ".\jdk1.5.0_10\include\win32" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TCFCLIENT_EXPORTS" /Fp"Release/TCFClient.pch" /Yc"stdafx.h" /Fo"Release/" /Fd"Release/" /FD /c
+"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFClient\StdAfx.cpp"
]
-Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP60D.tmp"
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP60E.tmp" with contents
+Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP91F.tmp"
+Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP920.tmp" with contents
[
-kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:no /pdb:"Release/TCFCommSerial.pdb" /map:"Release/TCFCommSerial.map" /machine:I386 /out:"Release/TCFCommSerial.dll" /implib:"Release/TCFCommSerial.lib"
-.\Release\BaseCom.obj
+kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib shlwapi.lib /nologo /dll /incremental:no /pdb:"Release/TCFClient.pdb" /map:"Release/TCFClient.map" /machine:I386 /out:"Release/TCFClient.dll" /implib:"Release/TCFClient.lib"
+.\Release\ClientManager.obj
+.\Release\ErrorMonitorData.obj
+.\Release\InputStream.obj
.\Release\mutex.obj
-.\Release\RealSerialComm.obj
+.\Release\ServerClient.obj
+.\Release\shareddata.obj
.\Release\StdAfx.obj
+.\Release\TCAPIConnectionJni.obj
.\Release\TCDebugLog.obj
-.\Release\TCFCommSerial.obj
+.\Release\TCFClient.obj
+.\Release\TCFCppApi.obj
+.\Release\resource.res
]
-Creating command line "link.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP60E.tmp"
+Creating command line "link.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP920.tmp"
<h3>Output Window</h3>
+Compiling resources...
Compiling...
StdAfx.cpp
Compiling...
-BaseCom.cpp
+ClientManager.cpp
+ErrorMonitorData.cpp
+InputStream.cpp
mutex.cpp
-RealSerialComm.cpp
+ServerClient.cpp
+shareddata.cpp
+TCAPIConnectionJni.cpp
TCDebugLog.cpp
-TCFCommSerial.cpp
+TCFClient.cpp
+TCFCppApi.cpp
Generating Code...
Linking...
- Creating library Release/TCFCommSerial.lib and object Release/TCFCommSerial.exp
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP612.bat" with contents
-[
-@echo off
-copyBinaries Release
-]
-Creating command line "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP612.bat"
-copy libs
-Copy binaries to ..\..\..\os\win32\x86
-The system cannot find the path specified.
- 0 file(s) copied.
-The system cannot find the path specified.
- 0 file(s) copied.
-The system cannot find the path specified.
- 0 file(s) copied.
-Error executing c:\winnt\system32\cmd.exe.
-
-
-
-<h3>Results</h3>
-TCFCommSerial.dll - 1 error(s), 0 warning(s)
-<h3>
---------------------Configuration: TCFCommTCP - Win32 Release--------------------
-</h3>
-<h3>Command Lines</h3>
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP613.tmp" with contents
-[
-/nologo /Zp2 /MT /W3 /GX /O2 /I "..\TCFServer" /I "..\Common\Headers" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TCFCOMMTCP_EXPORTS" /Fp"Release/TCFCommTCP.pch" /Yu"stdafx.h" /Fo"Release/" /Fd"Release/" /FD /c
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\BaseCom.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\mutex.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\TCDebugLog.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommTCP\TCFCommTCP.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommTCP\TcpComm.cpp"
-]
-Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP613.tmp"
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP614.tmp" with contents
-[
-/nologo /Zp2 /MT /W3 /GX /O2 /I "..\TCFServer" /I "..\Common\Headers" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TCFCOMMTCP_EXPORTS" /Fp"Release/TCFCommTCP.pch" /Yc"stdafx.h" /Fo"Release/" /Fd"Release/" /FD /c
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommTCP\StdAfx.cpp"
-]
-Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP614.tmp"
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP615.tmp" with contents
-[
-kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ws2_32.lib shlwapi.lib /nologo /dll /incremental:no /pdb:"Release/TCFCommTCP.pdb" /map:"Release/TCFCommTCP.map" /machine:I386 /out:"Release/TCFCommTCP.dll" /implib:"Release/TCFCommTCP.lib"
-.\Release\BaseCom.obj
-.\Release\mutex.obj
-.\Release\StdAfx.obj
-.\Release\TCDebugLog.obj
-.\Release\TCFCommTCP.obj
-.\Release\TcpComm.obj
-]
-Creating command line "link.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP615.tmp"
-<h3>Output Window</h3>
-Compiling...
-StdAfx.cpp
-Compiling...
-BaseCom.cpp
-mutex.cpp
-TCDebugLog.cpp
-TCFCommTCP.cpp
-TcpComm.cpp
-Generating Code...
-Linking...
- Creating library Release/TCFCommTCP.lib and object Release/TCFCommTCP.exp
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP619.bat" with contents
+ Creating library Release/TCFClient.lib and object Release/TCFClient.exp
+Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP924.bat" with contents
[
@echo off
copybinaries Release
]
-Creating command line "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP619.bat"
+Creating command line "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP924.bat"
copy libs
Copy binaries to ..\..\..\os\win32\x86
The system cannot find the path specified.
@@ -127,224 +82,7 @@
<h3>Results</h3>
-TCFCommTCP.dll - 1 error(s), 0 warning(s)
-<h3>
---------------------Configuration: TCFCommVirtualSerial - Win32 Release--------------------
-</h3>
-<h3>Command Lines</h3>
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP61A.tmp" with contents
-[
-/nologo /Zp2 /MT /W3 /GX /O2 /I "..\TCFCommSerial" /I "..\Common\Headers" /I "..\TCFServer" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TCFCOMMVIRTUALSERIAL_EXPORTS" /Fp"Release/TCFCommVirtualSerial.pch" /Yu"stdafx.h" /Fo"Release/" /Fd"Release/" /FD /c
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\BaseCom.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\mutex.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommSerial\RealSerialComm.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\TCDebugLog.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommVirtualSerial\TCFCommVirtualSerial.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommVirtualSerial\VirtualSerialComm.cpp"
-]
-Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP61A.tmp"
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP61B.tmp" with contents
-[
-/nologo /Zp2 /MT /W3 /GX /O2 /I "..\TCFCommSerial" /I "..\Common\Headers" /I "..\TCFServer" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TCFCOMMVIRTUALSERIAL_EXPORTS" /Fp"Release/TCFCommVirtualSerial.pch" /Yc"stdafx.h" /Fo"Release/" /Fd"Release/" /FD /c
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommVirtualSerial\StdAfx.cpp"
-]
-Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP61B.tmp"
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP61C.tmp" with contents
-[
-kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:no /pdb:"Release/TCFCommVirtualSerial.pdb" /map:"Release/TCFCommVirtualSerial.map" /machine:I386 /out:"Release/TCFCommVirtualSerial.dll" /implib:"Release/TCFCommVirtualSerial.lib"
-.\Release\BaseCom.obj
-.\Release\mutex.obj
-.\Release\RealSerialComm.obj
-.\Release\StdAfx.obj
-.\Release\TCDebugLog.obj
-.\Release\TCFCommVirtualSerial.obj
-.\Release\VirtualSerialComm.obj
-]
-Creating command line "link.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP61C.tmp"
-<h3>Output Window</h3>
-Compiling...
-StdAfx.cpp
-Compiling...
-BaseCom.cpp
-mutex.cpp
-RealSerialComm.cpp
-TCDebugLog.cpp
-TCFCommVirtualSerial.cpp
-VirtualSerialComm.cpp
-Generating Code...
-Linking...
- Creating library Release/TCFCommVirtualSerial.lib and object Release/TCFCommVirtualSerial.exp
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP620.bat" with contents
-[
-@echo off
-copyBinaries Release
-]
-Creating command line "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP620.bat"
-copy libs
-Copy binaries to ..\..\..\os\win32\x86
-The system cannot find the path specified.
- 0 file(s) copied.
-The system cannot find the path specified.
- 0 file(s) copied.
-The system cannot find the path specified.
- 0 file(s) copied.
-Error executing c:\winnt\system32\cmd.exe.
-
-
-
-<h3>Results</h3>
-TCFCommVirtualSerial.dll - 1 error(s), 0 warning(s)
-<h3>
---------------------Configuration: TCFProtOST - Win32 Release--------------------
-</h3>
-<h3>Command Lines</h3>
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP621.tmp" with contents
-[
-/nologo /Zp2 /MT /W3 /GX /O2 /I "..\TCFServer" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TCFPROTOST_EXPORTS" /Fp"Release/TCFProtOST.pch" /Yu"stdafx.h" /Fo"Release/" /Fd"Release/" /FD /c
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\BaseProtocol.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFProtOST\OSTProtocol.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFProtOST\TCFProtOST.cpp"
-]
-Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP621.tmp"
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP622.tmp" with contents
-[
-/nologo /Zp2 /MT /W3 /GX /O2 /I "..\TCFServer" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TCFPROTOST_EXPORTS" /Fp"Release/TCFProtOST.pch" /Yc"stdafx.h" /Fo"Release/" /Fd"Release/" /FD /c
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFProtOST\StdAfx.cpp"
-]
-Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP622.tmp"
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP623.tmp" with contents
-[
-kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:no /pdb:"Release/TCFProtOST.pdb" /map:"Release/TCFProtOST.map" /machine:I386 /out:"Release/TCFProtOST.dll" /implib:"Release/TCFProtOST.lib"
-.\Release\BaseProtocol.obj
-.\Release\OSTProtocol.obj
-.\Release\StdAfx.obj
-.\Release\TCFProtOST.obj
-]
-Creating command line "link.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP623.tmp"
-<h3>Output Window</h3>
-Compiling...
-StdAfx.cpp
-Compiling...
-BaseProtocol.cpp
-OSTProtocol.cpp
-TCFProtOST.cpp
-Generating Code...
-Linking...
- Creating library Release/TCFProtOST.lib and object Release/TCFProtOST.exp
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP627.bat" with contents
-[
-@echo off
-copyBinaries Release
-]
-Creating command line "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP627.bat"
-copy libs
-Copy binaries to ..\..\..\os\win32\x86
-The system cannot find the path specified.
- 0 file(s) copied.
-The system cannot find the path specified.
- 0 file(s) copied.
-The system cannot find the path specified.
- 0 file(s) copied.
-Error executing c:\winnt\system32\cmd.exe.
-
-
-
-<h3>Results</h3>
-TCFProtOST.dll - 1 error(s), 0 warning(s)
-<h3>
---------------------Configuration: TCFServer - Win32 Release--------------------
-</h3>
-<h3>Command Lines</h3>
-Creating command line "rc.exe /l 0x409 /fo"Release/resource.res" /d "NDEBUG" "C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\resource.rc""
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP628.tmp" with contents
-[
-/nologo /Zp2 /MT /W3 /GX /O2 /I "..\Common\Headers" /I "..\Common\Source" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fp"Release/TCFServer.pch" /Yu"stdafx.h" /Fo"Release/" /Fd"Release/" /FD /c
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\Client.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\CommRegistryItem.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\Connection.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\ConnectionImpl.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\ErrorMonitorData.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\InputStream.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\MessageFile.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\mutex.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\ProtocolRegistryItem.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\Registry.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\RegistryImpl.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\ServerClient.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\ServerManager.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\shareddata.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\TCDebugLog.cpp"
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\TCFServer.cpp"
-]
-Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP628.tmp"
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP629.tmp" with contents
-[
-/nologo /Zp2 /MT /W3 /GX /O2 /I "..\Common\Headers" /I "..\Common\Source" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fp"Release/TCFServer.pch" /Yc"stdafx.h" /Fo"Release/" /Fd"Release/" /FD /c
-"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\StdAfx.cpp"
-]
-Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP629.tmp"
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP62A.tmp" with contents
-[
-kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ws2_32.lib shlwapi.lib /nologo /subsystem:console /incremental:no /pdb:"Release/TCFServer.pdb" /machine:I386 /out:"Release/TCFServer.exe"
-.\Release\Client.obj
-.\Release\CommRegistryItem.obj
-.\Release\Connection.obj
-.\Release\ConnectionImpl.obj
-.\Release\ErrorMonitorData.obj
-.\Release\InputStream.obj
-.\Release\MessageFile.obj
-.\Release\mutex.obj
-.\Release\ProtocolRegistryItem.obj
-.\Release\Registry.obj
-.\Release\RegistryImpl.obj
-.\Release\ServerClient.obj
-.\Release\ServerManager.obj
-.\Release\shareddata.obj
-.\Release\StdAfx.obj
-.\Release\TCDebugLog.obj
-.\Release\TCFServer.obj
-.\Release\resource.res
-]
-Creating command line "link.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP62A.tmp"
-<h3>Output Window</h3>
-Compiling resources...
-Compiling...
-StdAfx.cpp
-Compiling...
-Client.cpp
-CommRegistryItem.cpp
-Connection.cpp
-ConnectionImpl.cpp
-ErrorMonitorData.cpp
-InputStream.cpp
-MessageFile.cpp
-mutex.cpp
-ProtocolRegistryItem.cpp
-Registry.cpp
-RegistryImpl.cpp
-ServerClient.cpp
-ServerManager.cpp
-shareddata.cpp
-TCDebugLog.cpp
-TCFServer.cpp
-Generating Code...
-Linking...
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP62C.bat" with contents
-[
-@echo off
-copybinaries Release
-]
-Creating command line "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP62C.bat"
-copy binary
-Copy binaries to ..\..\..\os\win32\x86
-The system cannot find the path specified.
- 0 file(s) copied.
-Error executing c:\winnt\system32\cmd.exe.
-
-
-
-<h3>Results</h3>
-TCFServer.exe - 1 error(s), 0 warning(s)
+TCFClient.dll - 1 error(s), 0 warning(s)
</pre>
</body>
</html>
--- a/connectivity/com.nokia.tcf/native/TCFNative/TCFCommSerial/RealSerialComm.cpp Tue Jun 15 10:21:51 2010 -0500
+++ b/connectivity/com.nokia.tcf/native/TCFNative/TCFCommSerial/RealSerialComm.cpp Tue Jun 15 16:19:30 2010 -0500
@@ -366,7 +366,7 @@
long CRealSerialComm::ClosePort()
{
COMMLOGOPEN();
- COMMLOGS("CRealSerialComm::ClosePort\n");
+ COMMLOGA1("CRealSerialComm::ClosePort connected=%d\n", IsConnected());
long err = TCAPI_ERR_NONE;
@@ -443,8 +443,9 @@
// and there was some kind of error
if (lclNumBytes != inSize)
{
+ m_lastCommError = 0;
COMMLOGOPEN();
- COMMLOGA3("CRealSerialComm::SendDataToPort WriteFile not all bytes sent: lclNumBytes=%d inSize=%d err=%d\n", lclNumBytes, inSize, GetLastError());
+ COMMLOGA3("CRealSerialComm::SendDataToPort WriteFile not all bytes sent: lclNumBytes=%d inSize=%d err=%d\n", lclNumBytes, inSize, m_lastCommError);
COMMLOGCLOSE();
COMSTAT lclComStat;
@@ -468,7 +469,7 @@
m_lastCommError = lclErrorFlags;
err = TCAPI_ERR_COMM_ERROR;
COMMLOGOPEN();
- COMMLOGA1("CRealSerialComm::SendDataToPort ClearCommError succeeded lclErrorFlags=%d\n", m_lastCommError);
+ COMMLOGA1("CRealSerialComm::SendDataToPort ClearCommError succeeded lclErrorFlags=%d\n", lclErrorFlags);
COMMLOGCLOSE();
}
else
@@ -477,7 +478,7 @@
// therefore, since we are not doing overlapped I/O, this is an error.
err = TCAPI_ERR_COMM_ERROR;
COMMLOGOPEN();
- COMMLOGS("CRealSerialComm::SendDataToPort ClearCommError succeeded lclErrorFlags=0\n");
+ COMMLOGA1("CRealSerialComm::SendDataToPort ClearCommError succeeded lclErrorFlags=0 err=%d\n", m_lastCommError);
COMMLOGCLOSE();
// DUMPCOMSTAT(&lclComStat);
}
@@ -530,6 +531,9 @@
// Sleep(1);
if (!ClearCommError( m_hSerial, &lclErrorFlags, &lclComStat ))
{
+ if (!IsConnected())
+ return TCAPI_ERR_MEDIA_NOT_OPEN;
+
m_lastCommError = GetLastError();
err = TCAPI_ERR_COMM_ERROR;
--- a/connectivity/com.nokia.tcf/native/TCFNative/TCFCommVirtualSerial/TCFCommVirtualSerial.plg Tue Jun 15 10:21:51 2010 -0500
+++ b/connectivity/com.nokia.tcf/native/TCFNative/TCFCommVirtualSerial/TCFCommVirtualSerial.plg Tue Jun 15 16:19:30 2010 -0500
@@ -6,24 +6,13 @@
--------------------Configuration: TCFCommVirtualSerial - Win32 Debug--------------------
</h3>
<h3>Command Lines</h3>
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPAFA.tmp" with contents
+Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP90F.tmp" with contents
[
/nologo /Zp2 /MTd /W3 /Gm /GX /ZI /Od /I "..\TCFCommSerial" /I "..\Common\Headers" /I "..\TCFServer" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TCFCOMMVIRTUALSERIAL_EXPORTS" /Fp"Debug/TCFCommVirtualSerial.pch" /Yu"stdafx.h" /Fo"Debug/" /Fd"Debug/" /FD /GZ /c
-"C:\dev22clone\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\BaseCom.cpp"
-"C:\dev22clone\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\mutex.cpp"
-"C:\dev22clone\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommSerial\RealSerialComm.cpp"
-"C:\dev22clone\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\Common\Source\TCDebugLog.cpp"
-"C:\dev22clone\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommVirtualSerial\TCFCommVirtualSerial.cpp"
-"C:\dev22clone\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommVirtualSerial\VirtualSerialComm.cpp"
+"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommSerial\RealSerialComm.cpp"
]
-Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPAFA.tmp"
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPAFB.tmp" with contents
-[
-/nologo /Zp2 /MTd /W3 /Gm /GX /ZI /Od /I "..\TCFCommSerial" /I "..\Common\Headers" /I "..\TCFServer" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TCFCOMMVIRTUALSERIAL_EXPORTS" /Fp"Debug/TCFCommVirtualSerial.pch" /Yc"stdafx.h" /Fo"Debug/" /Fd"Debug/" /FD /GZ /c
-"C:\dev22clone\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFCommVirtualSerial\StdAfx.cpp"
-]
-Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPAFB.tmp"
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPAFC.tmp" with contents
+Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP90F.tmp"
+Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP910.tmp" with contents
[
kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:yes /pdb:"Debug/TCFCommVirtualSerial.pdb" /map:"Debug/TCFCommVirtualSerial.map" /debug /machine:I386 /out:"Debug/TCFCommVirtualSerial.dll" /implib:"Debug/TCFCommVirtualSerial.lib" /pdbtype:sept
.\Debug\BaseCom.obj
@@ -34,26 +23,17 @@
.\Debug\TCFCommVirtualSerial.obj
.\Debug\VirtualSerialComm.obj
]
-Creating command line "link.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPAFC.tmp"
+Creating command line "link.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP910.tmp"
<h3>Output Window</h3>
Compiling...
-StdAfx.cpp
-Compiling...
-BaseCom.cpp
-mutex.cpp
RealSerialComm.cpp
-TCDebugLog.cpp
-TCFCommVirtualSerial.cpp
-VirtualSerialComm.cpp
-Generating Code...
Linking...
- Creating library Debug/TCFCommVirtualSerial.lib and object Debug/TCFCommVirtualSerial.exp
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPB00.bat" with contents
+Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP911.bat" with contents
[
@echo off
copyBinaries Debug
]
-Creating command line "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPB00.bat"
+Creating command line "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP911.bat"
copy libs
Copy binaries to ..\..\..\os\win32\x86
The system cannot find the path specified.
Binary file connectivity/com.nokia.tcf/native/TCFNative/TCFNative.ncb has changed
Binary file connectivity/com.nokia.tcf/native/TCFNative/TCFNative.opt has changed
--- a/connectivity/com.nokia.tcf/native/TCFNative/TCFServer/ConnectionImpl.cpp Tue Jun 15 10:21:51 2010 -0500
+++ b/connectivity/com.nokia.tcf/native/TCFNative/TCFServer/ConnectionImpl.cpp Tue Jun 15 16:19:30 2010 -0500
@@ -27,7 +27,7 @@
extern BOOL gDoLogging;
#endif
-//#define LOG_CONNECTION
+#define LOG_CONNECTION
#if defined(LOG_CONNECTION) && defined(_DEBUG)
#define TCDEBUGOPEN() if (gDoLogging) { this->m_DebugLog->WaitForAccess(); }
#define TCDEBUGLOGS(s) if (gDoLogging) { sprintf(this->m_DebugLogMsg,"%s", s); this->m_DebugLog->log(this->m_DebugLogMsg); }
@@ -410,6 +410,7 @@
if (err == TCAPI_ERR_COMM_ERROR)
{
// EnterRetryPeriod(err, true, m_BaseComm->m_lastCommError);
+ HandleFatalPortError(err, true, m_BaseComm->m_lastCommError);
m_OsError = m_BaseComm->m_lastCommError;
}
}
@@ -662,6 +663,19 @@
return m_Registry->AddClient(client, numberIds, ids);
}
+long CConnectionImpl::HandleFatalPortError(long err, bool passOsErr, DWORD osErr)
+{
+ TCDEBUGOPEN();
+ TCDEBUGLOGA3("CConnectionImpl::HandleFatalPortError err=%d passOsErr=%d osErr=%d\n", err, passOsErr, osErr);
+ TCDEBUGCLOSE();
+
+ m_BaseComm->ClosePort();
+ m_Status = eDisconnected;
+
+ NotifyClientsCommError(err);
+
+ return TCAPI_ERR_NONE;
+}
void CConnectionImpl::NotifyClientsCommError(long tcfError, bool passOsError, DWORD osError)
{
// TCDEBUGOPEN();
@@ -769,6 +783,7 @@
{
MPLOGA2("MessageProcessor err = %d osError = %d\n", err, pThis->m_BaseComm->m_lastCommError);
// pThis->EnterRetryPeriod(err, true, pThis->m_BaseComm->m_lastCommError);
+ pThis->HandleFatalPortError(err, true, pThis->m_BaseComm->m_lastCommError);
}
else
{
@@ -786,8 +801,10 @@
if (err == TCAPI_ERR_COMM_ERROR)
{
+ MPLOGA2("MessageProcessor err = %d osError = %d\n", err, pThis->m_BaseComm->m_lastCommError);
// for this error we have os error, but we probably caught this in PollPort already
// pThis->EnterRetryPeriod(err, true, pThis->m_BaseComm->m_lastCommError);
+ pThis->HandleFatalPortError(err, true, pThis->m_BaseComm->m_lastCommError);
}
else if (err != TCAPI_ERR_NONE)
{
--- a/connectivity/com.nokia.tcf/native/TCFNative/TCFServer/ConnectionImpl.h Tue Jun 15 10:21:51 2010 -0500
+++ b/connectivity/com.nokia.tcf/native/TCFNative/TCFServer/ConnectionImpl.h Tue Jun 15 16:19:30 2010 -0500
@@ -48,6 +48,7 @@
long DoSendMessage(long encodeOption, BYTE protocolVersion, BOOL useMsgId, BYTE msgId, DWORD msgLength, BYTE* msg);
long DoRetryProcessing();
long EnterRetryPeriod(long err, bool passOsErr, DWORD osErr);
+ long HandleFatalPortError(long err, bool passOsErr, DWORD osErr);
BOOL PauseProcessing(); // pause processing thread (not exit)
BOOL RestartProcessing(); // restart processing after a pause
--- a/connectivity/com.nokia.tcf/native/TCFNative/TCFServer/TCFServer.plg Tue Jun 15 10:21:51 2010 -0500
+++ b/connectivity/com.nokia.tcf/native/TCFNative/TCFServer/TCFServer.plg Tue Jun 15 16:19:30 2010 -0500
@@ -3,71 +3,48 @@
<pre>
<h1>Build Log</h1>
<h3>
---------------------Configuration: TCFServer - Win32 Debug--------------------
+--------------------Configuration: TCFServer - Win32 Release--------------------
</h3>
<h3>Command Lines</h3>
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPAC9.tmp" with contents
+Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP918.tmp" with contents
[
-/nologo /Zp2 /MTd /W3 /Gm /GX /ZI /Od /I "..\Common\Headers" /I "..\Common\Source" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FR"Debug/" /Fp"Debug/TCFServer.pch" /Yu"stdafx.h" /Fo"Debug/" /Fd"Debug/" /FD /GZ /c
-"C:\dev22clone\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\ServerManager.cpp"
+/nologo /Zp2 /MT /W3 /GX /O2 /I "..\Common\Headers" /I "..\Common\Source" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /Fp"Release/TCFServer.pch" /Yu"stdafx.h" /Fo"Release/" /Fd"Release/" /FD /c
+"C:\dev22clone2\carbidecpp\connectivity\com.nokia.tcf\native\TCFNative\TCFServer\ConnectionImpl.cpp"
]
-Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPAC9.tmp"
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPACA.tmp" with contents
+Creating command line "cl.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP918.tmp"
+Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP919.tmp" with contents
[
-kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ws2_32.lib shlwapi.lib /nologo /subsystem:console /incremental:yes /pdb:"Debug/TCFServer.pdb" /debug /machine:I386 /out:"Debug/TCFServer.exe" /pdbtype:sept
-.\Debug\Client.obj
-.\Debug\CommRegistryItem.obj
-.\Debug\Connection.obj
-.\Debug\ConnectionImpl.obj
-.\Debug\ErrorMonitorData.obj
-.\Debug\InputStream.obj
-.\Debug\MessageFile.obj
-.\Debug\mutex.obj
-.\Debug\ProtocolRegistryItem.obj
-.\Debug\Registry.obj
-.\Debug\RegistryImpl.obj
-.\Debug\ServerClient.obj
-.\Debug\ServerManager.obj
-.\Debug\shareddata.obj
-.\Debug\StdAfx.obj
-.\Debug\TCDebugLog.obj
-.\Debug\TCFServer.obj
-.\Debug\resource.res
+kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ws2_32.lib shlwapi.lib /nologo /subsystem:console /incremental:no /pdb:"Release/TCFServer.pdb" /machine:I386 /out:"Release/TCFServer.exe"
+.\Release\Client.obj
+.\Release\CommRegistryItem.obj
+.\Release\Connection.obj
+.\Release\ConnectionImpl.obj
+.\Release\ErrorMonitorData.obj
+.\Release\InputStream.obj
+.\Release\MessageFile.obj
+.\Release\mutex.obj
+.\Release\ProtocolRegistryItem.obj
+.\Release\Registry.obj
+.\Release\RegistryImpl.obj
+.\Release\ServerClient.obj
+.\Release\ServerManager.obj
+.\Release\shareddata.obj
+.\Release\StdAfx.obj
+.\Release\TCDebugLog.obj
+.\Release\TCFServer.obj
+.\Release\resource.res
]
-Creating command line "link.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPACA.tmp"
+Creating command line "link.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP919.tmp"
<h3>Output Window</h3>
Compiling...
-ServerManager.cpp
+ConnectionImpl.cpp
Linking...
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPACC.tmp" with contents
-[
-/nologo /o"Debug/TCFServer.bsc"
-.\Debug\StdAfx.sbr
-.\Debug\Client.sbr
-.\Debug\CommRegistryItem.sbr
-.\Debug\Connection.sbr
-.\Debug\ConnectionImpl.sbr
-.\Debug\ErrorMonitorData.sbr
-.\Debug\InputStream.sbr
-.\Debug\MessageFile.sbr
-.\Debug\mutex.sbr
-.\Debug\ProtocolRegistryItem.sbr
-.\Debug\Registry.sbr
-.\Debug\RegistryImpl.sbr
-.\Debug\ServerClient.sbr
-.\Debug\ServerManager.sbr
-.\Debug\shareddata.sbr
-.\Debug\TCDebugLog.sbr
-.\Debug\TCFServer.sbr]
-Creating command line "bscmake.exe @C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPACC.tmp"
-Creating browse info file...
-<h3>Output Window</h3>
-Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPACD.bat" with contents
+Creating temporary file "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP91B.bat" with contents
[
@echo off
-copybinaries Debug
+copybinaries Release
]
-Creating command line "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSPACD.bat"
+Creating command line "C:\DOCUME~1\chpeckha\LOCALS~1\Temp\RSP91B.bat"
copy binary
Copy binaries to ..\..\..\os\win32\x86
The system cannot find the path specified.