PPPAPI, added const modifier on auth strings

This commit is contained in:
Sylvain Rochet 2014-12-24 19:05:19 +01:00
parent 61f0231ce0
commit 91356d2d03
2 changed files with 4 additions and 4 deletions

View File

@ -102,7 +102,7 @@ pppapi_do_ppp_set_auth(struct pppapi_msg_msg *msg)
* tcpip_thread context.
*/
void
pppapi_set_auth(ppp_pcb *pcb, u8_t authtype, char *user, char *passwd)
pppapi_set_auth(ppp_pcb *pcb, u8_t authtype, const char *user, const char *passwd)
{
struct pppapi_msg msg;
msg.function = pppapi_do_ppp_set_auth;

View File

@ -48,8 +48,8 @@ struct pppapi_msg_msg {
union {
struct {
u8_t authtype;
char *user;
char *passwd;
const char *user;
const char *passwd;
} setauth;
#if PPP_NOTIFY_PHASE
struct {
@ -113,7 +113,7 @@ struct pppapi_msg {
/* API for application */
ppp_pcb *pppapi_new(void);
void pppapi_set_default(ppp_pcb *pcb);
void pppapi_set_auth(ppp_pcb *pcb, u8_t authtype, char *user, char *passwd);
void pppapi_set_auth(ppp_pcb *pcb, u8_t authtype, const char *user, const char *passwd);
#if PPP_NOTIFY_PHASE
void pppapi_set_notify_phase_callback(ppp_pcb *pcb, ppp_notify_phase_cb_fn notify_phase_cb);
#endif /* PPP_NOTIFY_PHASE */