示例#1
0
文件: utils.c 项目: joedf/robogato
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;
}
示例#2
0
文件: utils.c 项目: TLMcode/robogato
int irc_connected(char *recvbuf) {
	if (instrf(recvbuf," %d ",RplMotdEnd) || instrf(recvbuf," %d ",ErrNoMotd))
		return 1;
	else
		return 0;
}