Opened 11 years ago

Closed 11 years ago

Last modified 11 years ago

#43280 closed defect (fixed)

cannot cancel fetch

Reported by: ryandesign (Ryan Carsten Schmidt) Owned by: neverpanic (Clemens Lang)
Priority: Normal Milestone:
Component: base Version: 2.2.99
Keywords: Cc: nerdling (Jeremy Lavergne)
Port:

Description

If I press ^C during fetching a distfile, MacPorts cancels fetching from that server, but then tries to fetch from the next server.

When I press ^C I want MacPorts to stop what it's doing and exit.

Change History (3)

comment:1 Changed 11 years ago by neverpanic (Clemens Lang)

Cc: cal@… removed
Owner: changed from macports-tickets@… to cal@…

Yes, I'm aware of that. It gets even worse in verbose mode, where ^C doesn't abort until the download is completed. The try-catch-block that wraps curl fetch needs to detect whether the download was stopped because of a signal, and if it was pass the error up instead of trying the next mirror.

The curl code also needs to make sure it aborts immediately when receiving a signal. I'm not sure how we can do given the way the curl API looks. We might have to switch to curl_multi_perform.

Last edited 11 years ago by neverpanic (Clemens Lang) (previous) (diff)

comment:2 Changed 11 years ago by nerdling (Jeremy Lavergne)

Cc: snc@… added

Cc Me!

comment:3 Changed 11 years ago by neverpanic (Clemens Lang)

Resolution: fixed
Status: newclosed

Fixed in r118713, r118714 and somewhat related r118715.

Note: See TracTickets for help on using tickets.