Opened 6 years ago

Closed 4 years ago

#8744 closed defect (invalid)

The show_msg() does not save correctly the errno value

Reported by: dgoulet Owned by: ioerror
Priority: Medium Milestone:
Component: Core Tor/Torsocks Version:
Severity: Keywords:
Cc: sysrqb Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

The "show_msg" function tries to save the errno of the caller but there
are multiple call sites *before* that can override the errno value.

This was actually the cause of some other bugs in the past, one being
https://trac.torproject.org/projects/tor/ticket/8043.

I think the best way to deal with this issue is for the caller to make sure errno is saved. In some situations, we might NOT want this function to restore a previous errno so it should not set it.

Child Tickets

Change History (1)

comment:1 Changed 4 years ago by dgoulet

Resolution: invalid
Status: newclosed

Applies to a deprecated version of torsocks. Closing.

Note: See TracTickets for help on using tickets.