reorg: stream_close: move to util for now

master
Michael Santos 5 years ago
parent 862ab6d313
commit ee0f59516b

@ -40,7 +40,6 @@ int xmppipe_muc_init(xmppipe_state_t *);
int xmppipe_presence_init(xmppipe_state_t *);
void event_loop(xmppipe_state_t *);
int handle_stdin(xmppipe_state_t *, int, char *, size_t);
void xmppipe_stream_close(xmppipe_state_t *);
void xmppipe_muc_join(xmppipe_state_t *);
void xmppipe_muc_unlock(xmppipe_state_t *);
@ -857,13 +856,6 @@ xmppipe_ping(xmppipe_state_t *state)
state->keepalive_fail++;
}
void
xmppipe_stream_close(xmppipe_state_t *state)
{
if (state->sm_enabled)
xmpp_send_raw_string(state->conn, "</stream:stream>");
}
static long long
xmppipe_strtonum(xmppipe_state_t *state, const char *nptr, long long minval,
long long maxval)

@ -130,6 +130,7 @@ char *xmppipe_conference(char *, char *);
char *xmppipe_mucjid(char *, char *);
void xmppipe_next_state(xmppipe_state_t *state, int status);
void xmppipe_stream_close(xmppipe_state_t *);
char *xmppipe_getenv(const char *);
char *xmppipe_strdup(const char *);

@ -270,3 +270,10 @@ xmppipe_next_state(xmppipe_state_t *state, int status)
state->status = status;
}
void
xmppipe_stream_close(xmppipe_state_t *state)
{
if (state->sm_enabled)
xmpp_send_raw_string(state->conn, "</stream:stream>");
}

Loading…
Cancel
Save