Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
savoirfairelinux
jami-daemon
Commits
f03f5101
Commit
f03f5101
authored
Sep 13, 2013
by
Tristan Matthews
Browse files
* #29736: presence: make status_data private
parent
961db4c6
Changes
2
Hide whitespace changes
Inline
Side-by-side
daemon/src/sip/sippresence.cpp
View file @
f03f5101
...
@@ -46,8 +46,8 @@
...
@@ -46,8 +46,8 @@
#define MAX_N_PRES_SUB_CLIENT 20
#define MAX_N_PRES_SUB_CLIENT 20
SIPPresence
::
SIPPresence
(
SIPAccount
*
acc
)
SIPPresence
::
SIPPresence
(
SIPAccount
*
acc
)
:
p
res_status_data
()
:
p
ublish_sess
()
,
p
ublish_sess
()
,
p
res_status_data_
()
,
enabled_
(
true
)
,
enabled_
(
true
)
,
acc_
(
acc
)
,
acc_
(
acc
)
,
pres_sub_server_list_
()
//IP2IP context
,
pres_sub_server_list_
()
//IP2IP context
...
@@ -88,7 +88,7 @@ SIPAccount * SIPPresence::getAccount() const
...
@@ -88,7 +88,7 @@ SIPAccount * SIPPresence::getAccount() const
pjsip_pres_status
*
SIPPresence
::
getStatus
()
pjsip_pres_status
*
SIPPresence
::
getStatus
()
{
{
return
&
pres_status_data
;
return
&
pres_status_data
_
;
}
}
int
SIPPresence
::
getModId
()
const
int
SIPPresence
::
getModId
()
const
...
@@ -125,11 +125,11 @@ void SIPPresence::updateStatus(bool status, const std::string ¬e)
...
@@ -125,11 +125,11 @@ void SIPPresence::updateStatus(bool status, const std::string ¬e)
else
// TODO: is there any other possibilities
else
// TODO: is there any other possibilities
DEBUG
(
"Presence : no activity"
);
DEBUG
(
"Presence : no activity"
);
pj_bzero
(
&
pres_status_data
,
sizeof
(
pres_status_data
));
pj_bzero
(
&
pres_status_data
_
,
sizeof
(
pres_status_data
_
));
pres_status_data
.
info_cnt
=
1
;
pres_status_data
_
.
info_cnt
=
1
;
pres_status_data
.
info
[
0
].
basic_open
=
status
;
pres_status_data
_
.
info
[
0
].
basic_open
=
status
;
pres_status_data
.
info
[
0
].
id
=
pj_str
(
"0"
);
/* todo: tuplie_id*/
pres_status_data
_
.
info
[
0
].
id
=
pj_str
(
"0"
);
/* todo: tuplie_id*/
pj_memcpy
(
&
pres_status_data
.
info
[
0
].
rpid
,
&
rpid
,
sizeof
(
pjrpid_element
));
pj_memcpy
(
&
pres_status_data
_
.
info
[
0
].
rpid
,
&
rpid
,
sizeof
(
pjrpid_element
));
/* "contact" field is optionnal */
/* "contact" field is optionnal */
}
}
...
...
daemon/src/sip/sippresence.h
View file @
f03f5101
...
@@ -211,9 +211,9 @@ public:
...
@@ -211,9 +211,9 @@ public:
void
lock
();
void
lock
();
void
unlock
();
void
unlock
();
pjsip_pres_status
pres_status_data
;
/**< Presence Data.*/
pjsip_publishc
*
publish_sess
;
/**< Client publication session.*/
pjsip_publishc
*
publish_sess
;
/**< Client publication session.*/
private:
private:
pjsip_pres_status
pres_status_data_
;
/**< Presence Data.*/
pj_bool_t
enabled_
;
/**< Allow for status publish,*/
pj_bool_t
enabled_
;
/**< Allow for status publish,*/
NON_COPYABLE
(
SIPPresence
);
NON_COPYABLE
(
SIPPresence
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment