Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

getsegbyname(3) [opendarwin man page]

GETSEGBYNAME(3) 					     Library Functions Manual						   GETSEGBYNAME(3)

NAME
getsegbyname - get the segment command for the named segment SYNOPSIS
#include <mach-o/getsect.h> const struct segment_command *getsegbyname(const char *segname); DESCRIPTION
This routine returns the segment_command structure for the named segment if it exists in the Mach-O (Mach object) executable getsegby- name(3) is linked into. Otherwise getsegbyname(3) returns NULL. It uses the link editor defined symbol _mh_execute_header and just looks through the load commands. Since these are mapped into the __TEXT segment they are read-only and thus const by default. SEE ALSO
end(3), getsectbyname(3) Apple Computer, Inc. April 10, 1998 GETSEGBYNAME(3)

Check Out this Related Man Page

GETSECTBYNAME(3)					     Library Functions Manual						  GETSECTBYNAME(3)

NAME
getsectbyname, getsectdata - get the section information for the named section SYNOPSIS
#include <mach-o/getsect.h> const struct section *getsectbynamefromheader( const struct mach_header *mhp, const char *segname, const char *sectname) const struct section *getsectbyname( const char *segname, const char *sectname) char *getsectdatafromheader( const struct mach_header *mhp, const char *segname, const char *sectname, unsigned long *size) char *getsectdata( const char *segname, const char *sectname, unsigned long *size) char *getsectdatafromFramework( const char *FrameworkName, const char *segname, const char *sectname, unsigned long *size) DESCRIPTION
Getsectbynamefromheader returns the section structure for the named section in the named segment if it exists in the specified Mach header otherwise it returns NULL. If the specified Mach header comes from a dynamic library as returned by _dyld_get_image_header(3) the addr field in the section structure will have to have _dyld_get_image_vmaddr_slide(3) added to it to make it a valid pointer. Getsectbyname is the same as getsectbynamefromheader with its first argument being the link editor defined symbol _mh_execute_header. Getsectdatafromheader returns the address to the data for the named section in the named segment if it exists in the specified Mach header. Also it returns the size of the section data indirectly through the pointer size. Otherwise it returns NULL for the pointer and zero for the size. If the specified Mach header comes from a dynamic library as returned by _dyld_get_image_header(3) the address to the data returned will have to have _dyld_get_image_vmaddr_slide(3) added to it to make it a valid pointer. Getsectdata is the same as getsectdatafromheader with its first argument being the link editor defined symbol _mh_execute_header. getsectdatafromFramework is used to get the named section data from the named Framework. For example, the framework name ``Appkit'' would be used for /System/Library/Frameworks/Appkit.framework/Versions/C/Appkit. If that Framework isn't being used by the program then it returns NULL for the pointer and zero for the size. SEE ALSO
dyld(3), getsegbyname(3) Apple Computer, Inc. April 10, 1998 GETSECTBYNAME(3)
Man Page

2 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Shopt -s histappend

What is the point of this? Whenever I close my shell it appends to the history file without adding this. I have never seen it overwrite my history file. # When the shell exits, append to the history file instead of overwriting it shopt -s histappend (3 Replies)
Discussion started by: cokedude
3 Replies

2. OS X (Apple)

Undeletable file

Greetings, I'm trying to delete a file with a weird name from within Terminal on a Mac. It's a very old file (1992) with null characters in the name: “␀␀Word FinderÂŽ Plus™”. Here are some examples of what I've tried: 12FX009:5 dpontius$ ls ␀␀Word FinderÂŽ Plus™ 12FX009:5 dpontius$ rm... (29 Replies)
Discussion started by: dpontius
29 Replies