Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Core » unexpected output while reading the size of structure.
Re: unexpected output while reading the size of structure. [message #34755 is a reply to message #34753] Sat, 10 December 2011 08:54 Go to previous messageGo to previous message
Shwetha is currently offline  Shwetha
Messages: 39
Registered: August 2011
Member
Hi,

Using struct PACKED we can read the size of the structure correctly.

#ifndef PACKED
#define PACKED  __attribute__((__packed__))
#endif

typedef struct  PACKED
		{
			int i;
			char c;
			double d;
			
		}read_data;
		
	read_data r;
	
	
};


Thanks & Regards,

Shwetha S
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: dli file for Oracle10g
Next Topic: gdk_pixbuf-2.0 linker error
Goto Forum:
  


Current Time: Sat Aug 02 21:36:50 CEST 2025

Total time taken to generate the page: 0.09506 seconds