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 166277 Details for
Bug 310744
Patch for the routing issue
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]
Fix the filter_id lost issue
sci.patch (text/plain), 2.79 KB, created by
Tu Hong Jun
on 2010-04-27 22:52:13 EDT
(
hide
)
Description:
Fix the filter_id lost issue
Filename:
MIME Type:
Creator:
Tu Hong Jun
Created:
2010-04-27 22:52:13 EDT
Size:
2.79 KB
patch
obsolete
>Index: routerproc.cpp >=================================================================== >--- routerproc.cpp (revision 1843) >+++ routerproc.cpp (working copy) >@@ -62,7 +62,7 @@ > Message *msg = NULL; > msg = inQueue->consume(); > >- if (msg && (msg->getType() == Message::SEGMENT) && (msg->getFilterID() == SCI_ROUTE_SEGMENT)) { >+ if (msg && (msg->getType() == Message::SEGMENT) && (msg->getFilterID() == SCI_JOIN_SEGMENT)) { > int segnum = msg->getID() - 1; // exclude the SEGMENT header > Message **segments = (Message **)::malloc(segnum * sizeof(Message *)); > inQueue->remove(); >Index: routinglist.cpp >=================================================================== >--- routinglist.cpp (revision 1843) >+++ routinglist.cpp (working copy) >@@ -58,11 +58,14 @@ > } > > RoutingList::RoutingList() >+ : maxSegmentSize(TCP_ETHERNET_MTU * 32) > { > int hndl = gCtrlBlock->getMyHandle(); > char *envp = ::getenv("SCI_SEGMENT_SIZE"); >- if ((envp == NULL) || ((maxSegmentSize = ::atoi(envp)) <= TCP_ETHERNET_MTU)) >- maxSegmentSize = TCP_ETHERNET_MTU * 32; >+ if (envp != NULL) { >+ maxSegmentSize = atoi(envp); >+ maxSegmentSize = maxSegmentSize > TCP_ETHERNET_MTU ? maxSegmentSize : TCP_ETHERNET_MTU * 32; >+ } > > if (hndl == -1) { > // this is a front end, not parent >@@ -208,23 +211,24 @@ > sci_group_t gid = msg->getGroup(); > Message::Type typ = msg->getType(); > int mid = msg->getID(); >- int fid = msg->getFilterID(); >+ int mfid = msg->getFilterID(); >+ int hfid = mfid; > int mlen = msg->getContentLen(); > *segments = (Message **)::malloc(segnum * sizeof(Message *)); > Message **segs = *segments; > >- if ((fid != SCI_FILTER_NULL) || (typ != Message::COMMAND)) { >- fid = SCI_ROUTE_SEGMENT; >+ if ((mfid != SCI_FILTER_NULL) || (typ != Message::COMMAND)) { >+ hfid = SCI_JOIN_SEGMENT; > } > ::memset(segs, 0, segnum * sizeof(Message *)); > segs[0] = new Message(); >- segs[0]->build(fid, gid, 0, NULL, NULL, Message::SEGMENT, segnum); >+ segs[0]->build(hfid, gid, 0, NULL, NULL, Message::SEGMENT, segnum); > segs[0]->setRefCount(ref); > > for (i = 1; i < segnum; i++) { > segs[i] = new Message(); > size = (i < (segnum - 1)) ? maxSegmentSize : (mlen % maxSegmentSize); >- segs[i]->build(fid, gid, 1, &ptr, &size, typ, mid); >+ segs[i]->build(mfid, gid, 1, &ptr, &size, typ, mid); > segs[i]->setRefCount(ref); > ptr += size; > } >Index: routinglist.hpp >=================================================================== >--- routinglist.hpp (revision 1843) >+++ routinglist.hpp (working copy) >@@ -33,7 +33,7 @@ > class DistributedGroup; > class Stream; > >-#define SCI_ROUTE_SEGMENT -1001 >+#define SCI_JOIN_SEGMENT -1001 > > > class RoutingList
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 310744
: 166277