Bug 4727 - socket: consider write size of zero as error
Summary: socket: consider write size of zero as error
Status: NEW
Alias: None
Product: Claws Mail
Classification: Unclassified
Component: Other (show other bugs)
Version: 4.3.0
Hardware: PC All
: P3 normal
Assignee: users
URL:
Depends on:
Blocks:
 
Reported: 2024-01-06 12:56 UTC by olaf
Modified: 2024-02-01 11:06 UTC (History)
0 users

See Also:


Attachments
gtk2-socket-consider-write-size-of-zero-as-error.patch (1.11 KB, patch)
2024-01-06 12:56 UTC, olaf
Details | Diff
master-socket-consider-write-size-of-zero-as-error.patch (1.11 KB, patch)
2024-01-06 12:56 UTC, olaf
Details | Diff

Description olaf 2024-01-06 12:56:25 UTC
Created attachment 2384 [details]
gtk2-socket-consider-write-size-of-zero-as-error.patch

As a followup to bug#4726, handle a write size of zero for all transmission paths as error. This matches other parts of the code base, such as fd_write_all.

Neither the gnutls nor the POSIX documentation mentions a write size of
zero specifically. It is apparently up to each application to decide
what to do with such short write results. So in case of Claws Mail,
consider it an error in all cases.
Comment 1 olaf 2024-01-06 12:56:52 UTC
Created attachment 2385 [details]
master-socket-consider-write-size-of-zero-as-error.patch

Note You need to log in before you can comment on or make changes to this bug.