JustPaste.it

return 0
}

# Determines whether the user land is 32 or 64-bit.
#
# Side effects:
# None.
#
# Returns:
# "x86" or "x64" on success with error code 0. Exits with non-zero
# status and undefined text on failure.
get_arch() {
# First byte is the ELF magic number. The 5th byte is whether it's
# a 32 or 64-bit machine (1 or 2, respectively). See `man elf` for
# details.
local ELF_MAGIC=7f

if [ "`od -N1 -An -t x1 < /bin/sh | tr -d ' '`" != "$ELF_MAGIC" ]; then
exit 1
fi

local arch=`od -j4 -N1 -An -t u1 < /bin/sh | tr -d ' '`

<hay fin de lĂ­nea][convertido] 1671084L, 695556602C