Compare commits

...

2 Commits

Author SHA1 Message Date
Edi De Candido 2ce624ab70 include structures 2023-05-15 09:23:17 +02:00
Edi De Candido 67e555cb28 change int to unsigned short 2023-05-15 09:22:52 +02:00
2 changed files with 5 additions and 2 deletions

View File

@ -1,6 +1,8 @@
#ifndef SHM_H
#define SHM_H
#include <structures.h>
int getShmid(int row, int col);
tile_t * shmServerAt(int shmid);
tile_t * shmClientAt(int shmid);

View File

@ -1,6 +1,7 @@
#include <sys/sem.h>
#include <sys/stat.h>
#include <custom_sem.h>
#include <structures.h>
#include <errExit.h>
void semOp(int semid, short sem_num, short sem_op) {
@ -17,7 +18,7 @@ int getSemid(){
errExit("semget", "getSemid");
}
int val[] = {0, 0};
unsigned short val[] = {0, 0};
union semun arg;
arg.array = val;