[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: printf fails in version 5.2.026-3
From: |
Sam James |
Subject: |
Re: printf fails in version 5.2.026-3 |
Date: |
Wed, 03 Jul 2024 23:40:49 +0100 |
szigetva@delg0.elte.hu writes:
> Configuration Information [Automatically generated, do not change]:
> Machine: x86_64
> OS: linux-gnu
> Compiler: gcc
> Compilation CFLAGS: -march=x86-64 -mtune=generic -O2 -pipe -fno-plt
> -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security
> -fstack-clash-protection -fcf-protection -g
> -ffile-prefix-map=/build/bash/src=/usr/src/debug/bash -flto=auto
> -DDEFAULT_PATH_VALUE='/usr/local/sbin:/usr/local/bin:/usr/bin'
> -DSTANDARD_UTILS_PATH='/usr/bin' -DSYS_BASHRC='/etc/bash.bashrc'
> -DSYS_BASH_LOGOUT='/etc/bash.bash_logout'
> -DNON_INTERACTIVE_LOGIN_SHELLS
> uname output: Linux delg0 6.6.36-1-lts #1 SMP PREEMPT_DYNAMIC Thu, 27 Jun
> 2024 12:26:27 +0000 x86_64 GNU/Linux
> Machine Type: x86_64-pc-linux-gnu
>
> Bash Version: 5.2
> Patch Level: 26
> Release Status: release
>
> Description:
> printf works in version 5.2.026-2, fails in version 5.2.026-3
>
> Repeat-By:
> contents of tmp.sh begins --------
> #!/usr/bin/env bash
> a=1
> printf "%.2f\n" "$a"
> contents of tmp.sh ends ----------
>
> 5.2.026-2> ./tmp.sh
> 1.00
>
> 5.2.026-3> ./tmp.hs
> nan
>
> Fix:
> I don't understand what is happening, my current fix is downgrading to
> 5.2.026-2.
I suspect, based on your environment, that you're using Arch Linux or a
derivative. See
https://gitlab.archlinux.org/archlinux/packaging/packages/bash/-/issues/3.