Project Homepage | Sourceforge Page | CVS Repository | Freshmeat.net Page | Download project | Author's Homepage |
00001 /*!\file comboHandlers.h 00002 \brief various handlers based on comboBox data 00003 \note This stuff will be moved to more appropriate files in the near 00004 future. 00005 */ 00006 /* NOTICE: 00007 Copyright (C) 2004 Karl N. Redman (SleepingStill.com) 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 2 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, write to the Free Software 00021 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 00022 00023 For further information contact: parasyte@sleepingstill.com 00024 */ 00025 00026 #ifndef _COMBOHANDLERS_H_ 00027 #define _COMBOHANDLERS_H_ 00028 00029 #ifdef HAVE_CONFIG_H 00030 # include <config.h> 00031 #endif 00032 00033 00034 /** @name command line lengths 00035 * Figure out the maximum command line lengths for the current shell 00036 */ 00037 //@{ 00038 #ifndef RF_LINE_MAX_LEN 00039 #ifdef RF_BIG_VALUES 00040 #include <unistd.h> 00041 /// use the maximum line length available 00042 #define RF_LINE_MAX_LEN sysconf(ARG_MAX) 00043 #else 00044 /// use a standard line length 00045 //#define RF_LINE_MAX_LEN 255 00046 #define RF_LINE_MAX_LEN 1026 00047 #endif //RF_BIG_VALUES 00048 #endif //RF_DEFAULT_LINE_MAX_LEN 00049 //@} 00050 00051 ///free a GList object and all it's members 00052 void freeList(GList *list); 00053 ///read a history file 00054 GList *readHistory(GList *list, char *filename); 00055 ///write to a history file (append) 00056 int writeHistory(char *command, char *filename); 00057 00058 #endif //_COMBOHANDLERS_H_