Skip to content

Commit

Permalink
ims: removed trailing spaces
Browse files Browse the repository at this point in the history
  • Loading branch information
miconda committed Nov 13, 2023
1 parent 8e08fa2 commit e3a8d1b
Show file tree
Hide file tree
Showing 3 changed files with 54 additions and 54 deletions.
46 changes: 23 additions & 23 deletions src/lib/ims/ims_getters.c
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
/*
* Copyright (C) 2012 Smile Communications, jason.penton@smilecoms.com
* Copyright (C) 2012 Smile Communications, richard.good@smilecoms.com
*
*
* The initial version of this code was written by Dragos Vingarzan
* (dragos(dot)vingarzan(at)fokus(dot)fraunhofer(dot)de and the
* Fruanhofer Institute. It was and still is maintained in a separate
* branch of the original SER. We are therefore migrating it to
* Kamailio/SR and look forward to maintaining it from here on out.
* 2011/2012 Smile Communications, Pty. Ltd.
* ported/maintained/improved by
* ported/maintained/improved by
* Jason Penton (jason(dot)penton(at)smilecoms.com and
* Richard Good (richard(dot)good(at)smilecoms.com) as part of an
* Richard Good (richard(dot)good(at)smilecoms.com) as part of an
* effort to add full IMS support to Kamailio/SR using a new and
* improved architecture
*
*
* NB: Alot of this code was originally part of OpenIMSCore,
* FhG Fokus.
* FhG Fokus.
* Copyright (C) 2004-2006 FhG Fokus
* Thanks for great work! This is an effort to
* Thanks for great work! This is an effort to
* break apart the various CSCF functions into logically separate
* components. We hope this will drive wider use. We also feel
* that in this way the architecture is more complete and thereby easier
Expand All @@ -35,10 +35,10 @@
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
*
*/

#include "../../core/parser/msg_parser.h"
Expand All @@ -59,7 +59,7 @@

/**
* Delete parameters and stuff from uri.
* @param uri - the string to operate on
* @param uri - the string to operate on
*/
static inline void cscf_strip_uri(str *uri)
{
Expand Down Expand Up @@ -364,7 +364,7 @@ str cscf_get_public_identity_from(struct sip_msg *msg)
* Returns the expires value from the Expires header in the message.
* It searches into the Expires header and if not found returns -1
* @param msg - the SIP message, if available
* @is_shm - msg from from shared memory
* @is_shm - msg from from shared memory
* @returns the value of the expire or -1 if not found
*/
int cscf_get_expires_hdr(struct sip_msg *msg, int is_shm)
Expand Down Expand Up @@ -401,7 +401,7 @@ int cscf_get_expires_hdr(struct sip_msg *msg, int is_shm)

/**
* Returns the expires value from the message.
* First it searches into the Expires header and if not found it also looks
* First it searches into the Expires header and if not found it also looks
* into the expires parameter in the contact header
* @param msg - the SIP message
* @param is_shm - msg from shared memory
Expand Down Expand Up @@ -490,7 +490,7 @@ str cscf_get_public_identity_from_requri(struct sip_msg *msg)
* NB: free returned result str when done from shm
* @param msg - the SIP message
* @returns the contact (don't forget to free from shm)
*
*
* NOTE: should only be called when REQ URI has been converted sip:user@IP_ADDRESS:PORT or tel:IP_ADDRESS:PORT
*/
str cscf_get_contact_from_requri(struct sip_msg *msg)
Expand Down Expand Up @@ -659,7 +659,7 @@ str cscf_get_asserted_identity(struct sip_msg *msg, int is_shm)

static str phone_context_s = {";phone-context=", 15};
/**
* Extracts the realm from a SIP/TEL URI.
* Extracts the realm from a SIP/TEL URI.
* - SIP - the hostname
* - TEL - the phone-context parameter
* @param msg - the SIP message
Expand Down Expand Up @@ -742,9 +742,9 @@ str cscf_get_realm_from_uri(str uri)
return realm;
}

/**
/**
* Delivers the Realm from request URI
* @param msg sip message
* @param msg sip message
* @returns realm as String on success 0 on fail
*/
str cscf_get_realm_from_ruri(struct sip_msg *msg)
Expand All @@ -765,7 +765,7 @@ str cscf_get_realm_from_ruri(struct sip_msg *msg)
/**
* Looks for the Call-ID header
* @param msg - the sip message
* @param hr - ptr to return the found hdr_field
* @param hr - ptr to return the found hdr_field
* @returns the callid value
*/
str cscf_get_call_id(struct sip_msg *msg, struct hdr_field **hr)
Expand Down Expand Up @@ -915,7 +915,7 @@ int cscf_add_header_first(struct sip_msg *msg, str *hdr, int type)
* @param msg - the SIP message to look into
* @param header_name - the name of the header to search for
* @param last_header - last header to ignore in the search, or NULL if to start from the first one
* @returns the hdr_field on success or NULL if not found
* @returns the hdr_field on success or NULL if not found
*/
struct hdr_field *cscf_get_next_header(
struct sip_msg *msg, str header_name, struct hdr_field *last_header)
Expand Down Expand Up @@ -1089,7 +1089,7 @@ int cscf_add_header(struct sip_msg *msg, str *hdr, int type)
}

/**
* Get the expires header value from a message.
* Get the expires header value from a message.
* @param msg - the SIP message
* @returns the expires value or -1 if not found
*/
Expand All @@ -1113,7 +1113,7 @@ static str prack_s = {"PRACK", 5};
static str update_s = {"UPDATE", 6};
static str notify_s = {"NOTIFY", 6};
/**
* Check if the message is an initial request for a dialog.
* Check if the message is an initial request for a dialog.
* - BYE, PRACK, UPDATE, NOTIFY belong to an already existing dialog
* @param msg - the message to check
* @returns 1 if initial, 0 if not
Expand Down Expand Up @@ -1170,7 +1170,7 @@ int cscf_get_originating_user(struct sip_msg *msg, str *uri)
* returns in uri the freshly pkg allocated uri - don't forget to free
* @param msg - the SIP message
* @param uri - uri to fill into
* @returns 1 if found, else 0
* @returns 1 if found, else 0
*/
int cscf_get_terminating_user(struct sip_msg *msg, str *uri)
{
Expand Down Expand Up @@ -1757,7 +1757,7 @@ int cscf_add_header_rpl(struct sip_msg *msg, str *hdr)
/**
* Looks for the Call-ID header
* @param msg - the sip message
* @param hr - ptr to return the found hdr_field
* @param hr - ptr to return the found hdr_field
* @returns the callid value
*/
int cscf_get_cseq(struct sip_msg *msg, struct hdr_field **hr)
Expand Down Expand Up @@ -1800,7 +1800,7 @@ static str s_called_party_id = {"P-Called-Party-ID", 17};
/**
* Looks for the P-Called-Party-ID header and extracts the public identity from it
* @param msg - the sip message
* @param hr - ptr to return the found hdr_field
* @param hr - ptr to return the found hdr_field
* @returns the P-Called_Party-ID
*/
str cscf_get_public_identity_from_called_party_id(
Expand Down
44 changes: 22 additions & 22 deletions src/lib/ims/ims_getters.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,16 @@
* branch of the original SER. We are therefore migrating it to
* Kamailio/SR and look forward to maintaining it from here on out.
* 2011/2012 Smile Communications, Pty. Ltd.
* ported/maintained/improved by
* ported/maintained/improved by
* Jason Penton (jason(dot)penton(at)smilecoms.com and
* Richard Good (richard(dot)good(at)smilecoms.com) as part of an
* Richard Good (richard(dot)good(at)smilecoms.com) as part of an
* effort to add full IMS support to Kamailio/SR using a new and
* improved architecture
*
*
* NB: Alot of this code was originally part of OpenIMSCore,
* FhG Fokus.
* FhG Fokus.
* Copyright (C) 2004-2006 FhG Fokus
* Thanks for great work! This is an effort to
* Thanks for great work! This is an effort to
* break apart the various CSCF functions into logically separate
* components. We hope this will drive wider use. We also feel
* that in this way the architecture is more complete and thereby easier
Expand All @@ -36,10 +36,10 @@
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
*
*/

#ifndef __IMS_GETTERS_H
Expand Down Expand Up @@ -73,7 +73,7 @@ enum cscf_dialog_direction
* - malloc failed
* \Note On any error, the dst values are reset for safety
* \Note A label "out_of_memory" must be defined in the calling function to handle
* allocation errors.
* allocation errors.
* @param dst - destination str
* @param src - source src
* @param mem - type of mem to duplicate into (shm/pkg)
Expand Down Expand Up @@ -147,13 +147,13 @@ str cscf_get_public_identity_from(struct sip_msg *msg);
* Returns the expires value from the Expires header in the message.
* It searches into the Expires header and if not found returns -1
* @param msg - the SIP message, if available
* @is_shm - msg from from shared memory
* @is_shm - msg from from shared memory
* @returns the value of the expire or -1 if not found
*/
int cscf_get_expires_hdr(struct sip_msg *msg, int is_shm);
/**
* Returns the expires value from the message.
* First it searches into the Expires header and if not found it also looks
* First it searches into the Expires header and if not found it also looks
* into the expires parameter in the contact header
* @param msg - the SIP message
* @param is_shm - msg from shared memory
Expand All @@ -176,16 +176,16 @@ int cscf_has_originating(struct sip_msg *msg, char *str1, char *str2);
*/
str cscf_get_asserted_identity(struct sip_msg *msg, int is_shm);
/**
* Extracts the realm from a SIP/TEL URI.
* Extracts the realm from a SIP/TEL URI.
* - SIP - the hostname
* - TEL - the phone-context parameter
* @param msg - the SIP message
* @returns the realm
*/
str cscf_get_realm_from_uri(str uri);
/**
/**
* Delivers the Realm from request URI
* @param msg sip message
* @param msg sip message
* @returns realm as String on success 0 on fail
*/
str cscf_get_realm_from_ruri(struct sip_msg *msg);
Expand All @@ -201,15 +201,15 @@ str cscf_get_public_identity_from_requri(struct sip_msg *msg);
* NB: free returned result str when done from shm
* @param msg - the SIP message
* @returns the contact (don't forget to free from shm)
*
*
* NOTE: should only be called when REQ URI has been converted sip:user@IP_ADDRESS:PORT or tel:IP_ADDRESS:PORT
*/
str cscf_get_contact_from_requri(struct sip_msg *msg);

/**
* Looks for the Call-ID header
* @param msg - the sip message
* @param hr - ptr to return the found hdr_field
* @param hr - ptr to return the found hdr_field
* @returns the callid value
*/
str cscf_get_call_id(struct sip_msg *msg, struct hdr_field **hr);
Expand Down Expand Up @@ -240,7 +240,7 @@ int cscf_add_header_first(struct sip_msg *msg, str *hdr, int type);
* @param msg - the SIP message to look into
* @param header_name - the name of the header to search for
* @param last_header - last header to ignore in the search, or NULL if to start from the first one
* @returns the hdr_field on success or NULL if not found
* @returns the hdr_field on success or NULL if not found
*/
struct hdr_field *cscf_get_next_header(struct sip_msg *msg,
/**
Expand Down Expand Up @@ -279,13 +279,13 @@ str cscf_get_authenticate(struct sip_msg *msg, struct hdr_field **h);
*/
int cscf_add_header(struct sip_msg *msg, str *hdr, int type);
/**
* Get the expires header value from a message.
* Get the expires header value from a message.
* @param msg - the SIP message
* @returns the expires value or -1 if not found
*/
int cscf_get_expires(struct sip_msg *msg);
/**
* Check if the message is an initial request for a dialog.
* Check if the message is an initial request for a dialog.
* - BYE, PRACK, UPDATE, NOTIFY belong to an already existing dialog
* @param msg - the message to check
* @returns 1 if initial, 0 if not
Expand All @@ -305,7 +305,7 @@ int cscf_get_originating_user(struct sip_msg *msg, str *uri);
* returns in uri the freshly pkg allocated uri - don't forget to free
* @param msg - the SIP message
* @param uri - uri to fill into
* @returns 1 if found, else 0
* @returns 1 if found, else 0
*/
int cscf_get_terminating_user(struct sip_msg *msg, str *uri);

Expand Down Expand Up @@ -444,15 +444,15 @@ int cscf_add_header_rpl(struct sip_msg *msg, str *hdr);
/**
* Looks for the Call-ID header
* @param msg - the sip message
* @param hr - ptr to return the found hdr_field
* @param hr - ptr to return the found hdr_field
* @returns the callid value
*/
int cscf_get_cseq(struct sip_msg *msg, struct hdr_field **hr);

/**
* Looks for the P-Called-Party-ID header and extracts the public identity from it
* @param msg - the sip message
* @param hr - ptr to return the found hdr_field
* @param hr - ptr to return the found hdr_field
* @returns the P-Called_Party-ID
*/
str cscf_get_public_identity_from_called_party_id(
Expand Down
18 changes: 9 additions & 9 deletions src/lib/ims/useful_defs.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,23 +3,23 @@
*
* Copyright (C) 2012 Smile Communications, jason.penton@smilecoms.com
* Copyright (C) 2012 Smile Communications, richard.good@smilecoms.com
*
*
* The initial version of this code was written by Dragos Vingarzan
* (dragos(dot)vingarzan(at)fokus(dot)fraunhofer(dot)de and the
* Fruanhofer Institute. It was and still is maintained in a separate
* branch of the original SER. We are therefore migrating it to
* Kamailio/SR and look forward to maintaining it from here on out.
* 2011/2012 Smile Communications, Pty. Ltd.
* ported/maintained/improved by
* ported/maintained/improved by
* Jason Penton (jason(dot)penton(at)smilecoms.com and
* Richard Good (richard(dot)good(at)smilecoms.com) as part of an
* Richard Good (richard(dot)good(at)smilecoms.com) as part of an
* effort to add full IMS support to Kamailio/SR using a new and
* improved architecture
*
*
* NB: Alot of this code was originally part of OpenIMSCore,
* FhG Fokus.
* FhG Fokus.
* Copyright (C) 2004-2006 FhG Fokus
* Thanks for great work! This is an effort to
* Thanks for great work! This is an effort to
* break apart the various CSCF functions into logically separate
* components. We hope this will drive wider use. We also feel
* that in this way the architecture is more complete and thereby easier
Expand All @@ -37,10 +37,10 @@
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
*
*/

#define STR_SHM_DUP(dest, src, txt) \
Expand Down

0 comments on commit e3a8d1b

Please sign in to comment.