CARS
|
00001 00007 /* Copyright (C) 2011 Nicola Corti 00008 00009 This program is free software: you can redistribute it and/or modify 00010 it under the terms of the GNU General Public License as published by 00011 the Free Software Foundation, either version 3 of the License, or 00012 (at your option) any later version. 00013 00014 This program is distributed in the hope that it will be useful, 00015 but WITHOUT ANY WARRANTY; without even the implied warranty of 00016 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00017 GNU General Public License for more details. 00018 00019 You should have received a copy of the GNU General Public License 00020 along with this program. If not, see <http://www.gnu.org/licenses/>. 00021 00022 For further information, Nicola Corti - <cortin [at] cli.di.unipi.it> 00023 */ 00024 #include <stdlib.h> 00025 00026 #ifndef __SETTINGS_H 00027 #define __SETTINGS_H 00028 00029 /* ===================== PARAMETRI DEL SISTEMA ===================== 00030 * 00031 * Questo file contiene le impostazioni per il sistema Cars 00032 * 00033 * Le modifiche a questo file verranno rese effettive soltanto dopo una 00034 * ricompilazione di ENTRAMBI il client e il server. 00035 * 00036 * ATTENZIONE! 00037 * Avere dei client che sono stati compilati con una determinata 00038 * impostazione ed avere altri che sono stati compilati con impostazioni 00039 * differenti puo' portare ad un malfunzionamento del sistema 00040 * 00041 * ATTENZIONE! 00042 * Modificare i valori delle macro soltanto entro quanto indicato 00043 * dai commenti. Inserire valori differenti puo' portare ad un serio 00044 * malfunzionamento del sistema, o all'impossibilita' di ricompilare il codice. 00045 * 00046 * NOTA: 00047 * Nel caso in cui si volesse riportare lo stato alla condizione iniziale 00048 * e possibile recuperare il file settings.h contenuto nella cartella ../doc/settings 00049 */ 00050 00063 #define SOCKET_PATH "./tmp/cars.sck" 00064 00083 #define NSEC_TIMER 0 00084 00102 #define LOG_FILE_NAME "./mgcars.log" 00103 00122 #define PERM_FILE (S_IRUSR | S_IWUSR | S_IXUSR | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH) 00123 00151 #define POOL_SIZE 8 00152 00180 #define MAX_TRY 5 00181 00188 #define DELAY 1 00189 00211 #define PROMPT "client> " 00212 00234 /* #define UPDATE_OFFER */ 00235 00260 #define FREE_OFFER_LIST 00261 00279 /* #define VERBOSE */ 00280 00281 00282 00283 /* 00284 * ========================================================================== 00285 * 00286 * MACRO AVANZATE 00287 * 00288 * Modificare questi valori solo se si e' consapevoli delle conseguenze 00289 * ========================================================================== 00290 */ 00291 00318 #define CHAR_LENGTH 4 00319 00325 #define BUFF_SIZE 512 00326 00342 #define MAX_PID_CHAR 6 00343 00344 /* ***************** */ 00345 #endif