bugfix: max connection must great than 0

This commit is contained in:
云风
2012-09-07 00:28:09 +08:00
parent f8d271c1a0
commit 87b8b664aa

View File

@@ -244,6 +244,10 @@ gate_init(struct gate *g , struct skynet_context * ctx, char * parm) {
skynet_error(ctx, "Invalid gate parm %s",parm);
return 1;
}
if (max <=0 ) {
skynet_error(ctx, "Need max conntection");
return 1;
}
if (header != 'S' && header !='L') {
skynet_error(ctx, "Invalid data header style");
return 1;