Skip to content

Commit f60c9e7

Browse files
committed
Correct indent mistake.
modified: dwarf_rnglists.c Remove trailing whitespace modified: libdwarf.h
1 parent a01681e commit f60c9e7

File tree

2 files changed

+37
-14
lines changed

2 files changed

+37
-14
lines changed

src/lib/libdwarf/dwarf_rnglists.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1274,8 +1274,8 @@ int
12741274
dwarf_rnglists_get_rle_head(
12751275
Dwarf_Attribute attr,
12761276
Dwarf_Half theform,
1277-
/* attr_val is either an offset
1278-
(theform == DW_FORM_sec_offset)
1277+
/* attr_val is either an offset
1278+
(theform == DW_FORM_sec_offset)
12791279
or an index DW_FORM_rnglistx. */
12801280
Dwarf_Unsigned attr_val,
12811281
Dwarf_Rnglists_Head *head_out,

src/lib/libdwarf/libdwarf.h

Lines changed: 35 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,7 @@ extern "C" {
115115
#define DW_FTYPE_MACH_O 2 /* MacOS. */
116116
#define DW_FTYPE_PE 3 /* Windows */
117117
#define DW_FTYPE_ARCHIVE 4 /* unix archive */
118+
#define DW_FTYPE_APPLEUNIVERSAL 5
118119
#endif /* DW_FTYPE_UNKNOWN */
119120
/* standard return values for functions */
120121
#define DW_DLV_NO_ENTRY -1
@@ -1385,9 +1386,10 @@ typedef struct Dwarf_Rnglists_Head_s * Dwarf_Rnglists_Head;
13851386
#define DW_DLE_LINE_INDEX_WRONG 499
13861387
#define DW_DLE_LINE_COUNT_WRONG 500
13871388
#define DW_DLE_ARITHMETIC_OVERFLOW 501
1389+
#define DW_DLE_UNIVERSAL_BINARY_ERROR 502
13881390

13891391
/*! @note DW_DLE_LAST MUST EQUAL LAST ERROR NUMBER */
1390-
#define DW_DLE_LAST 501
1392+
#define DW_DLE_LAST 502
13911393
#define DW_DLE_LO_USER 0x10000
13921394
/*! @} */
13931395

@@ -1457,6 +1459,16 @@ DW_API int dwarf_init_path(const char * dw_path,
14571459
Dwarf_Debug* dw_dbg,
14581460
Dwarf_Error* dw_error);
14591461

1462+
DW_API int dwarf_init_path_a(const char * dw_path,
1463+
char * dw_true_path_out_buffer,
1464+
unsigned int dw_true_path_bufferlen,
1465+
unsigned int dw_groupnumber,
1466+
unsigned int dw_universalnumber,
1467+
Dwarf_Handler dw_errhand,
1468+
Dwarf_Ptr dw_errarg,
1469+
Dwarf_Debug* dw_dbg,
1470+
Dwarf_Error* dw_error);
1471+
14601472
/*! @brief Initialization following GNU debuglink section data.
14611473
14621474
Sets the true-path with DWARF if there is
@@ -1525,6 +1537,19 @@ DW_API int dwarf_init_path_dl(const char * dw_path,
15251537
unsigned char * dw_dl_path_source,
15261538
Dwarf_Error* dw_error);
15271539

1540+
DW_API int dwarf_init_path_dl_a(const char * dw_path,
1541+
char * dw_true_path_out_buffer,
1542+
unsigned int dw_true_path_bufferlen,
1543+
unsigned int dw_groupnumber,
1544+
unsigned int dw_universalnumber,
1545+
Dwarf_Handler dw_errhand,
1546+
Dwarf_Ptr dw_errarg,
1547+
Dwarf_Debug* dw_dbg,
1548+
char ** dw_dl_path_array,
1549+
unsigned int dw_dl_path_array_size,
1550+
unsigned char * dw_dl_path_source,
1551+
Dwarf_Error* dw_error);
1552+
15281553
/*! @brief Initialization based on Unix/Linux (etc) path
15291554
This version allows specifying any number of debuglink
15301555
global paths to search on for debuglink targets.
@@ -5402,7 +5427,7 @@ DW_API int dwarf_get_fde_info_for_reg3_b(Dwarf_Fde dw_fde,
54025427
dwarf_get_fde_info_for_reg3_c but
54035428
it refers to the CFA (which is not part of the register
54045429
table) so function has no table column argument.
5405-
5430+
54065431
New in September 2023, release 0.8.0.
54075432
dwarf_get_fde_info_for_cfa_reg3_c() returns dw_offset
54085433
as a signed type.
@@ -8852,6 +8877,14 @@ DW_API Dwarf_Small dwarf_set_default_address_size(
88528877

88538878
/*! @defgroup objectdetector Determine Object Type of a File
88548879
@{
8880+
8881+
This group of functions are unlikely to be called
8882+
by your code unless your code needs to know
8883+
the basic data about an object file without
8884+
actually opening a Dwarf_Debug.
8885+
8886+
These are crucial for libdwarf itself.
8887+
88558888
*/
88568889
DW_API int dwarf_object_detector_path_b(const char * dw_path,
88578890
char *dw_outpath_buffer,
@@ -8884,16 +8917,6 @@ DW_API int dwarf_object_detector_fd(int dw_fd,
88848917
unsigned int *dw_offsetsize,
88858918
Dwarf_Unsigned *dw_filesize,
88868919
int *dw_errcode);
8887-
#if 0
8888-
/* Added September 2023 for Mach-O universal binaries */
8889-
DW_API int dwarf_object_detector_fd_a(int dw_fd,
8890-
unsigned int *dw_ftype,
8891-
unsigned int *dw_endian,
8892-
unsigned int *dw_offsetsize,
8893-
Dwarf_Unsigned *dw_startingoffset,
8894-
Dwarf_Unsigned *dw_filesize,
8895-
int *dw_errcode);
8896-
#endif
88978920

88988921
/*! @}
88998922
*/

0 commit comments

Comments
 (0)