/* $Id$ * Include file for FUSE interface module utf8 conversions for libcaptive * Copyright (C) 2002-2005 Jan Kratochvil * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; exactly version 2 of June 1991 is required * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #ifndef _CAPTIVE_CLIENT_FUSE_UTF8_H #define _CAPTIVE_CLIENT_FUSE_UTF8_H 1 #include G_BEGIN_DECLS char *capfuse_filename_to_utf8_malloc_errorchecking(const char *name); char *capfuse_filename_from_utf8_malloc_errorchecking(const char *name); #define CAPFUSE_FILENAME_TO_UTF8_ALLOCA(name) ({ \ const char *_capfuse_filename_to_utf8_alloca_name=(name); \ char *_capfuse_filename_to_utf8_alloca_r_malloc; \ const char *_capfuse_filename_to_utf8_alloca_r; \ \ _capfuse_filename_to_utf8_alloca_r_malloc=capfuse_filename_to_utf8_malloc_errorchecking( \ _capfuse_filename_to_utf8_alloca_name); \ if (!_capfuse_filename_to_utf8_alloca_r_malloc) \ _capfuse_filename_to_utf8_alloca_r=_capfuse_filename_to_utf8_alloca_name; \ else { \ _capfuse_filename_to_utf8_alloca_r=captive_strdup_alloca(_capfuse_filename_to_utf8_alloca_r_malloc); \ g_free(_capfuse_filename_to_utf8_alloca_r_malloc); \ } \ _capfuse_filename_to_utf8_alloca_r; \ }) G_END_DECLS #endif /* _CAPTIVE_CLIENT_FUSE_UTF8_H */