Bug 1052846

Summary: ftell stuck on file opened w+ for writing wide characters
Product: [Fedora] Fedora Reporter: Siddhesh Poyarekar <spoyarek>
Component: glibcAssignee: Siddhesh Poyarekar <spoyarek>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: ashankar, codonell, fweimer, jakub, law, mnewsome, pfrankli, spoyarek
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-01-14 09:13:41 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Reproducer program none

Description Siddhesh Poyarekar 2014-01-14 08:19:02 UTC
Created attachment 849788 [details]
Reproducer program

ftell gets stuck in an infinite loop when it is called after an fputsw (obviously for wide characters) and the buffer is not full, but does not have enough space to convert the current wide character.

How Reproducible:

Always

Steps to Reproduce:

Build and run attached reproducer.

Actual Behaviour:

Infinite loop

Expected behaviour:

Program returns.