Project

General

Profile

Actions

Bug #14937

open

iconv_close(-1) should fail with EBADF

Added by Marcel Telka 4 months ago. Updated 4 months ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
lib - userland libraries
Start date:
Due date:
% Done:

0%

Estimated time:
Difficulty:
Bite-size
Tags:
Gerrit CR:
External Bug:

Description

The (iconv_1)-1 conversion descriptor is returned by iconv_open(3c) in a case of failure so it would be great if we could simply pass this to iconv_close(3c) without seeing segfault as we do see now.

Actions #1

Updated by Marcel Telka 4 months ago

Please note that on linux iconv_close((iconv_t)-1) returns -1 and errno is set to EBADF.

Actions

Also available in: Atom PDF