Navigation


Changeset 1212:c38bb8b69c43 in freeDiameter


Ignore:
Timestamp:
Jun 17, 2013, 7:19:53 PM (11 years ago)
Author:
Sebastien Decugis <sdecugis@freediameter.net>
Branch:
default
Phase:
public
Message:

Fix message rtd handling for extensions based on this data

Files:
4 edited

Legend:

Unmodified
Added
Removed
  • extensions/dbg_interactive/messages.i

    r1127 r1212  
    342342        void set_rtd(struct rt_data *DISOWN) {
    343343                struct rt_data * r = DISOWN;
    344                 int ret = fd_msg_rt_associate($self, &r);
     344                int ret = fd_msg_rt_associate($self, r);
    345345                if (ret != 0) {
    346346                        DI_ERROR(ret, NULL, NULL);
  • include/freeDiameter/libfdproto.h

    r1193 r1212  
    25022502 *  EINVAL: a parameter is invalid
    25032503 */
    2504 int fd_msg_rt_associate( struct msg * msg, struct rt_data ** rtd );
     2504int fd_msg_rt_associate( struct msg * msg, struct rt_data * rtd );
    25052505int fd_msg_rt_get      ( struct msg * msg, struct rt_data ** rtd );
    25062506
  • libfdcore/routing_dispatch.c

    r1190 r1212  
    943943                        CHECK_FCT(  fd_msg_browse(avp, MSG_BRW_NEXT, &avp, NULL)  );
    944944                }
     945               
     946                /* Save the routing information in the message */
     947                CHECK_FCT( fd_msg_rt_associate ( msgptr, rtd ) );
    945948        }
    946949
     
    985988        /* Order the candidate peers by score attributed by the callbacks */
    986989        CHECK_FCT( fd_rtd_candidate_reorder(candidates) );
    987 
    988         /* Save the routing information in the message */
    989         CHECK_FCT( fd_msg_rt_associate ( msgptr, &rtd ) );
    990990
    991991        /* Now try sending the message */
  • libfdproto/messages.c

    r1205 r1212  
    12981298
    12991299/* Associate routing lists */
    1300 int fd_msg_rt_associate( struct msg * msg, struct rt_data ** rtd )
     1300int fd_msg_rt_associate( struct msg * msg, struct rt_data * rtd )
    13011301{
    13021302        TRACE_ENTRY( "%p %p", msg, rtd );
     
    13041304        CHECK_PARAMS(  CHECK_MSG(msg) && rtd  );
    13051305       
    1306         msg->msg_rtdata = *rtd;
    1307         *rtd = NULL;
     1306        msg->msg_rtdata = rtd;
    13081307       
    13091308        return 0;
     
    13171316       
    13181317        *rtd = msg->msg_rtdata;
    1319         msg->msg_rtdata = NULL;
    13201318       
    13211319        return 0;
Note: See TracChangeset for help on using the changeset viewer.