int irc_identified(char *recvbuf) { if (instr(recvbuf,"You are now identified")) return 1; if (instrf(recvbuf," %d ",ErrUserOnChannel)) return -1; if (instrf(recvbuf," %d ",ErrNickNameInUse)) return -1; if (instr(recvbuf,"Invalid password")) return -1; if (instr(recvbuf,"Nick/channel is temporarily unavailable")) return -1; return 0; }
int irc_connected(char *recvbuf) { if (instrf(recvbuf," %d ",RplMotdEnd) || instrf(recvbuf," %d ",ErrNoMotd)) return 1; else return 0; }