Bug 647320 - unicap.h uses "private" keyword as variable name
Summary: unicap.h uses "private" keyword as variable name
Alias: None
Product: Fedora EPEL
Classification: Fedora
Component: libunicap
Version: el5
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Robert Scheck
QA Contact: Fedora Extras Quality Assurance
Depends On: 642118
TreeView+ depends on / blocked
Reported: 2010-10-27 21:17 UTC by Todd Zullinger
Modified: 2010-11-18 17:21 UTC (History)
4 users (show)

Fixed In Version: libunicap-0.9.12-7.el5
Doc Type: Bug Fix
Doc Text:
Clone Of: 642118
Last Closed: 2010-10-29 22:38:53 UTC
Type: ---

Attachments (Terms of Use)

Description Todd Zullinger 2010-10-27 21:17:46 UTC
+++ This bug was initially created as a clone of Bug #642118 +++

Description of problem:
When compiling a C++ program with unicap.h, the following error occurs:

/usr/include/unicap/unicap.h:218:34: error: expected unqualified-id before ‘private’
/usr/include/unicap/unicap.h:218:34: error: expected ‘;’ before ‘private’

Upon further inspection, line 218 of unicap.h contains the following:
   unicap_data_buffer_private_t *private;

The "private" C++ keyword is being used here as a member name inside of a struct, which is preventing g++ from using unicap.h

Version-Release number of selected component (if applicable):

How reproducible:
Compile a C++ program with unicap.h included.

Steps to Reproduce:
1. Create file "unicaptest.cpp" with trivial program:
  #include "unicap.h"
  int main(){}
2. Run g++ `pkg-config --cflags libunicap` -o unicaptest unicaptest.cpp
3. View error.
Actual results:
Program fails to compile, with above error

Expected results:
Program compiles 

Additional info:
Test case compiles when the file extension is changed to .c and gcc is used.

--- Additional comment from kdudka on 2010-10-12 03:14:55 EDT ---

Thank you for filing the bug.  It seems to be already reported upstream, although on a completely wrong place:


--- Additional comment from kdudka on 2010-10-12 07:35:21 EDT ---

fixed in libunicap-0.9.12-4.fc15

--- Additional comment from kdudka on 2010-10-13 05:50:18 EDT ---

upstream bug:


Comment 1 Fedora Update System 2010-10-29 22:38:32 UTC
libunicap-0.9.12-5.el5 has been submitted as an update for Fedora EPEL 5.

Comment 2 Fedora Update System 2010-11-02 16:07:03 UTC
libunicap-0.9.12-7.el5 has been submitted as an update for Fedora EPEL 5.

Comment 3 Fedora Update System 2010-11-18 17:21:14 UTC
libunicap-0.9.12-7.el5 has been pushed to the Fedora EPEL 5 stable repository.  If problems still persist, please make note of it in this bug report.

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