dwarf_init.c (241844) | dwarf_init.c (252430) |
---|---|
1/*- 2 * Copyright (c) 2007 John Birrell (jb@freebsd.org) 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 9 unchanged lines hidden (view full) --- 18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24 * SUCH DAMAGE. 25 * | 1/*- 2 * Copyright (c) 2007 John Birrell (jb@freebsd.org) 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 9 unchanged lines hidden (view full) --- 18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24 * SUCH DAMAGE. 25 * |
26 * $FreeBSD: head/lib/libdwarf/dwarf_init.c 241844 2012-10-22 03:00:37Z eadler $ | 26 * $FreeBSD: head/lib/libdwarf/dwarf_init.c 252430 2013-06-30 21:06:47Z kaiw $ |
27 */ 28 29#include <stdlib.h> 30#include <string.h> 31#include "_libdwarf.h" 32 33static const char *debug_snames[DWARF_DEBUG_SNAMES] = { 34 ".debug_abbrev", --- 152 unchanged lines hidden (view full) --- 187 188 ret |= ((b & 0x7f) << shift); 189 190 (*offsetp)++; 191 192 shift += 7; 193 } while ((b & 0x80) != 0); 194 | 27 */ 28 29#include <stdlib.h> 30#include <string.h> 31#include "_libdwarf.h" 32 33static const char *debug_snames[DWARF_DEBUG_SNAMES] = { 34 ".debug_abbrev", --- 152 unchanged lines hidden (view full) --- 187 188 ret |= ((b & 0x7f) << shift); 189 190 (*offsetp)++; 191 192 shift += 7; 193 } while ((b & 0x80) != 0); 194 |
195 if (shift < 32 && (b & 0x40) != 0) | 195 if (shift < 64 && (b & 0x40) != 0) |
196 ret |= (-1 << shift); 197 198 return ret; 199} 200 201static uint64_t 202dwarf_read_uleb128(Elf_Data **dp, uint64_t *offsetp) 203{ --- 553 unchanged lines hidden --- | 196 ret |= (-1 << shift); 197 198 return ret; 199} 200 201static uint64_t 202dwarf_read_uleb128(Elf_Data **dp, uint64_t *offsetp) 203{ --- 553 unchanged lines hidden --- |