commit: r333 - trunk/libspread

[email protected]
Newsgroups gmane.network.spread.cvs
Message-ID <[email protected]>
Author: jonathan
Date: 2006-03-02 16:28:11 -0500 (Thu, 02 Mar 2006)
New Revision: 333

Modified:
   trunk/libspread/sp.c
Log:
Make old membership offset functions static so they are internal to the library.


Modified: trunk/libspread/sp.c
===================================================================
--- trunk/libspread/sp.c	2006-03-02 20:23:30 UTC (rev 332)
+++ trunk/libspread/sp.c	2006-03-02 21:28:11 UTC (rev 333)
@@ -1780,32 +1780,32 @@
 /* get membership info from a message */
 
 /* internal only for now -- maybe static? */
-int     SP_get_gid_offset_memb_mess(void) 
+static  int     SP_get_gid_offset_memb_mess(void) 
 {
         return 0;
 }
 
-int     SP_get_num_vs_sets_offset_memb_mess(void) 
+static  int     SP_get_num_vs_sets_offset_memb_mess(void) 
 {
         return sizeof(group_id);
 }
 
-int     SP_get_offset_to_local_vs_set_offset(void)
+static  int     SP_get_offset_to_local_vs_set_offset(void)
 {
         return sizeof(group_id) + sizeof(int32u);
 }
 
-int     SP_get_first_vs_set_offset_memb_mess(void) 
+static  int     SP_get_first_vs_set_offset_memb_mess(void) 
 {
         return sizeof(group_id) + 2*sizeof(int32u);
 }
 
-int     SP_get_vs_set_size_offset_vs_set(void)
+static  int     SP_get_vs_set_size_offset_vs_set(void)
 {
         return 0;
 }
 
-int     SP_get_vs_set_members_offset_vs_set(void)
+static  int     SP_get_vs_set_members_offset_vs_set(void)
 {
         return sizeof(int32u);
 }
@@ -2003,37 +2003,6 @@
 }
 
 
-int     SP_get_local_vs_set_offset_memb_mess( char *reg_memb_mess )
-{
-        int32u offset;
-        memcpy( &offset, &reg_memb_mess[SP_get_offset_to_local_vs_set_offset()],
-                sizeof(int32u) );
-        offset += SP_get_first_vs_set_offset_memb_mess();
-        return offset;
-}
-
-int     SP_get_local_vs_set_offset_memb_scat( const scatter *reg_memb_scat )
-{
-        int32u offset;
-        int     bytes_in = 0;
-        int     i, offset_location;
-        
-        offset_location = SP_get_offset_to_local_vs_set_offset();
-        for (i=0; i < reg_memb_scat->num_elements; i++) 
-        {
-            if ( bytes_in + reg_memb_scat->elements[i].len > offset_location )
-            {
-                /* offset is in this scatter element */
-                memcpy( &offset, &reg_memb_scat->elements[i].buf[offset_location - bytes_in], sizeof(int32u) );
-            } else {
-                bytes_in += reg_memb_scat->elements[i].len;
-            }
-        }
-
-        offset += SP_get_first_vs_set_offset_memb_mess();
-        return offset;
-}
-
 int	SP_query_groups( mailbox mbox, int max_groups, char *groups[MAX_GROUP_NAME] )
 {
 	return( -1 );
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.