Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 58753 Details for
Bug 173319
Agent Controller fails to start up due to shared memory TL error
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
modifed patch for transport components
transport1.txt (text/plain), 6.96 KB, created by
Igor Alelekov
on 2007-02-12 02:40:08 EST
(
hide
)
Description:
modifed patch for transport components
Filename:
MIME Type:
Creator:
Igor Alelekov
Created:
2007-02-12 02:40:08 EST
Size:
6.96 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.tptp.platform.agentcontroller >Index: src-native-new/src/transport/sharedMemTL/SharedMemListener.c >=================================================================== >RCS file: /cvsroot/tptp/platform/org.eclipse.tptp.platform.agentcontroller/src-native-new/src/transport/sharedMemTL/SharedMemListener.c,v >retrieving revision 1.25 >diff -u -r1.25 SharedMemListener.c >--- src-native-new/src/transport/sharedMemTL/SharedMemListener.c 27 Sep 2006 23:01:45 -0000 1.25 >+++ src-native-new/src/transport/sharedMemTL/SharedMemListener.c 12 Feb 2007 07:23:57 -0000 >@@ -71,7 +71,11 @@ > enum ThreadStatus { IDLE, RUNNING } ; > > static int acShmMemCount = 0; >+static int shMemInitialized = 0; > >+void destroyMem (mem_map_block_ptr_t pMemBlockInfo); >+ >+extern void ossSleep (long ms); > > /*====================================================================*/ > /* internal function prototypes */ >@@ -224,10 +228,8 @@ > else > { > pServerData->serverMemInfo = memBlockInfo ; >+ shMemInitialized = 1; > >- /* attach to this block so that it will not be deleted */ >- ipcMemOpen(pServerData->sharedMemName, &memBlockInfo); >- > /* create new thread to listen to connection request */ > rc = startNewThread(doListening, > (LPVOID) pServerData, &threadId, &threadHandle) ; >@@ -250,11 +252,37 @@ > > tptp_int32 stopSharedMemListener(server_block_t* pServerData) > { >+ int cnt; >+ > pServerData->threadStatus = IDLE ; >+ ipcStopFlusher (&pServerData->serverMemInfo); > >+ cnt = 20; >+ while (shMemInitialized && cnt-- > 0) { // wait 2 sec for flusher termination >+ ossSleep (100L); >+ } >+ >+ if (shMemInitialized) { >+ destroyMem (&pServerData->serverMemInfo); >+ } >+ > return 0 ; > } > >+/** >+ ********************************************************* >+ * >+ * @brief >+ * destroy shared memory block >+ * >+ *********************************************************/ >+ >+void destroyMem (mem_map_block_ptr_t pMemBlockInfo) { >+ ipcStopFlushing (pMemBlockInfo); // let shared memory get deleted when it is destroyed >+ ipcMemDestroy (pMemBlockInfo); >+ shMemInitialized = 0; >+} >+ > > /** > ********************************************************* >@@ -321,8 +349,6 @@ > return 0 ; > } > >- >- > /** > ********************************************************* > * >@@ -376,13 +402,15 @@ > > while (pServerData->threadStatus == RUNNING) > { >+ /* attach to this block so that it will not be deleted */ >+ ipcMemOpen(pServerData->sharedMemName, pMemBlockInfo); >+ > rc = ipcFlushToFunc(pMemBlockInfo, sharedMemMainDataProcessorFunc, (void *) pServerData) ; >- ipcMemOpen(pServerData->sharedMemName, pMemBlockInfo); >- } >+ } > > TPTP_LOG_DEBUG_MSG(pServerData, "Shared memory server ends...\n") ; > >- ipcMemDestroy(pMemBlockInfo); >+ destroyMem (pMemBlockInfo); > > return ( rc ) ; > } >Index: src-native-new/src/transport/sharedMemTL/SharedMemTL.dsp >=================================================================== >RCS file: /cvsroot/tptp/platform/org.eclipse.tptp.platform.agentcontroller/src-native-new/src/transport/sharedMemTL/SharedMemTL.dsp,v >retrieving revision 1.5 >diff -u -r1.5 SharedMemTL.dsp >--- src-native-new/src/transport/sharedMemTL/SharedMemTL.dsp 12 Sep 2005 18:05:00 -0000 1.5 >+++ src-native-new/src/transport/sharedMemTL/SharedMemTL.dsp 12 Feb 2007 07:23:57 -0000 >@@ -80,7 +80,7 @@ > # ADD BSC32 /nologo > LINK32=link.exe > # ADD BASE LINK32 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 /debug /machine:I386 /pdbtype:sept >-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib transportSupport.lib tptpUtils.lib /nologo /dll /debug /machine:I386 /def:".\sharedMemTL.def" /implib:"../../../lib/sharedMemTL.lib" /pdbtype:sept /libpath:"../../../lib" >+# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib transportSupport.lib tptpUtils.lib hcclsm.lib /nologo /dll /debug /machine:I386 /def:".\sharedMemTL.def" /implib:"../../../lib/sharedMemTL.lib" /pdbtype:sept /libpath:"../../../lib" > # SUBTRACT LINK32 /pdb:none > > !ENDIF >Index: src-native-new/src/transport/transportSupport/TransportSupport.def >=================================================================== >RCS file: /cvsroot/tptp/platform/org.eclipse.tptp.platform.agentcontroller/src-native-new/src/transport/transportSupport/TransportSupport.def,v >retrieving revision 1.15 >diff -u -r1.15 TransportSupport.def >--- src-native-new/src/transport/transportSupport/TransportSupport.def 12 Jan 2007 21:54:59 -0000 1.15 >+++ src-native-new/src/transport/transportSupport/TransportSupport.def 12 Feb 2007 07:23:57 -0000 >@@ -48,4 +48,5 @@ > getPeerIPString @45 > convertIPAddressUlongToString @46 > getSocketPort @47 >- >+ ipcStopFlusher @48 >+ >Index: src-native-new/src/transport/transportSupport/TransportSupportSharedMemExt.c >=================================================================== >RCS file: /cvsroot/tptp/platform/org.eclipse.tptp.platform.agentcontroller/src-native-new/src/transport/transportSupport/TransportSupportSharedMemExt.c,v >retrieving revision 1.7 >diff -u -r1.7 TransportSupportSharedMemExt.c >--- src-native-new/src/transport/transportSupport/TransportSupportSharedMemExt.c 5 Jun 2006 17:59:57 -0000 1.7 >+++ src-native-new/src/transport/transportSupport/TransportSupportSharedMemExt.c 12 Feb 2007 07:23:57 -0000 >@@ -25,6 +25,7 @@ > > //We need to reference this stop flushing routine. > extern tptp_int32 ra_setShmAttachCount(ra_shm_handle_t *, tptp_int32); >+extern tptp_int32 ra_stopFlusher(ra_shm_handle_t *); > > /** > ********************************************************* >@@ -97,4 +98,16 @@ > return ( rc ) ; > } > >+int ipcStopFlusher(mem_map_block_ptr_t pBlockInfo) >+{ >+ int rc = 0 ; >+ >+ ra_shm_handle_t *pShmHdl = (ra_shm_handle_t *) pBlockInfo->pRamboBlock ; >+ >+ if (pShmHdl != NULL) { >+ rc = ra_stopFlusher(pShmHdl); >+ } >+ >+ return ( rc ) ; >+} > >Index: src-native-new/include/tptp/TransportSupportSharedMem.h >=================================================================== >RCS file: /cvsroot/tptp/platform/org.eclipse.tptp.platform.agentcontroller/src-native-new/include/tptp/TransportSupportSharedMem.h,v >retrieving revision 1.10 >diff -u -r1.10 TransportSupportSharedMem.h >--- src-native-new/include/tptp/TransportSupportSharedMem.h 5 Apr 2006 23:57:20 -0000 1.10 >+++ src-native-new/include/tptp/TransportSupportSharedMem.h 12 Feb 2007 07:23:57 -0000 >@@ -239,6 +239,7 @@ > *********************************************************/ > > int ipcStopFlushing(mem_map_block_ptr_t pBlockInfo); >+int ipcStopFlusher(mem_map_block_ptr_t pBlockInfo); > > > #ifdef __cplusplus >@@ -247,5 +248,3 @@ > > > #endif >- >-
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 173319
:
58661
|
58662
| 58753 |
60903