본문/내용
#include
#include
#include `player.h`
#define MAX_PLAYER 10
#define FALSE 0
#define TRUE 1
void Player(int PlayerID,int PlayerNum,int PlayerData[MAX_PLAYER][5])
{
int ReadFD,WriteFD; // 읽기, 쓰기 파이프 파일 디스크립터
int UserPoint=0,GetUserPoint=0; // 비교값저장 변수, 임시 저장 변수
int TempData[5]; // 각각 사용자가 중복값을 가지고 있지 않은지 검사
char PIPENAME[10]; // 파이프 이름
double MyPID; // 경기자 PID
int IndexData, IndexPlayer; // 배열 인덱스
int Check; // 중복검사에 사용되는 인덱스
int Repetition = FALSE; // 중복 검사 플래그
// 파이프 오픈
sprintf(PIPENAME,`READPIPE%d`,PlayerID+1);
참고문헌
- 프로그래머와 사용자를 위한 UNXI 완성 완전한 안내서 조경산 역 이한출판사 2002 p.433-453, p511-534
- TCP/IP 소켓 프로그래밍 윤성우 FREELET 2004, p.21-37, p.263-p.277, p.231-p.239
- UNIX 시스템 프로그래밍 원유원, 백정현 정익사 1995 p.259-p.290
- UNIX NETWORK PROGRAMMING 김치하외1명 역 대영사 1992 p.244-p.259
- GNU Software GNU 소프트웨어로 프로그래밍하기 이기동 역 2000 한빛미디어 p.199-p.217
- unix.co.kr Unix System Programming 1~10 - 김성호(moohou)
http://unix.co.kr/stories.php?story=02/12/13/9474369
- http://www.chongju-e.ac.kr/~cmyang/lecture/cprg/socket.ppt
- http://kmh.ync.ac.kr/NetworkProg/network/basicfunc.html