00001 /* 00002 * This file is part of the SSH Library 00003 * 00004 * Copyright (c) 2009 by Aris Adamantiadis 00005 * 00006 * The SSH Library is free software; you can redistribute it and/or modify 00007 * it under the terms of the GNU Lesser General Public License as published by 00008 * the Free Software Foundation; either version 2.1 of the License, or (at your 00009 * option) any later version. 00010 * 00011 * The SSH Library is distributed in the hope that it will be useful, but 00012 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 00013 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public 00014 * License for more details. 00015 * 00016 * You should have received a copy of the GNU Lesser General Public License 00017 * along with the SSH Library; see the file COPYING. If not, write to 00018 * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, 00019 * MA 02111-1307, USA. 00020 */ 00021 00022 #ifndef STRING_H_ 00023 #define STRING_H_ 00024 #include "libssh/priv.h" 00025 00026 /* must be 32 bits number + immediately our data */ 00027 #ifdef _MSC_VER 00028 #pragma pack(1) 00029 #endif 00030 struct ssh_string_struct { 00031 uint32_t size; 00032 unsigned char string[MAX_PACKET_LEN]; 00033 } 00034 #if !defined(__SUNPRO_C) && !defined(_MSC_VER) 00035 __attribute__ ((packed)) 00036 #endif 00037 #ifdef _MSC_VER 00038 #pragma pack() 00039 #endif 00040 ; 00041 00042 #endif /* STRING_H_ */