Re: [PATCH v6? 15/17] refs API: make resolve_ref_unsafe() not set errno

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Jul 11, 2021 at 6:30 PM Ævar Arnfjörð Bjarmason
<avarab@xxxxxxxxx> wrote:
> +       refs = get_main_ref_store(the_repository);
> +       head = refs_resolve_ref_unsafe_with_errno(refs, "HEAD", 0, NULL, NULL,
> +                                                 &resolve_errno);
> +       if (!head) {
> +               errno = resolve_errno;

This adds another place where we'd use global errno to communicate.
Isn't there a die() function that takes an errno value explicitly?

-- 
Han-Wen Nienhuys - Google Munich
I work 80%. Don't expect answers from me on Fridays.
--

Google Germany GmbH, Erika-Mann-Strasse 33, 80636 Munich

Registergericht und -nummer: Hamburg, HRB 86891

Sitz der Gesellschaft: Hamburg

Geschäftsführer: Paul Manicle, Halimah DeLaine Prado




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux