libdebian-installer
|
00001 /* 00002 * string.h 00003 * 00004 * Copyright (C) 2003 Bastian Blank <waldi@debian.org> 00005 * 00006 * This program is free software; you can redistribute it and/or modify 00007 * it under the terms of the GNU General Public License as published by 00008 * the Free Software Foundation; either version 2 of the License, or 00009 * (at your option) any later version. 00010 * 00011 * This program is distributed in the hope that it will be useful, 00012 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00014 * GNU General Public License for more details. 00015 * 00016 * You should have received a copy of the GNU General Public License 00017 * along with this program. If not, see <http://www.gnu.org/licenses/>. 00018 */ 00019 00020 #ifndef DEBIAN_INSTALLER__STRING_H 00021 #define DEBIAN_INSTALLER__STRING_H 00022 00023 #include <debian-installer/types.h> 00024 00025 #include <stdio.h> 00026 00027 typedef struct di_rstring di_rstring; 00028 00037 struct di_rstring 00038 { 00039 char *string; 00040 di_ksize_t size; 00041 }; 00042 00051 int di_snprintfcat (char *str, size_t size, const char *format, ...) 00052 #ifdef __GNUC__ 00053 __attribute__ ((format (printf, 3, 4))) 00054 #endif 00055 ; 00056 00064 char *di_stradup (const char *s, size_t n); 00065 00067 #endif