bugGNU dbm - Bugs: bug #515, gdbm.h misses sys/types.h include...

 
 
Show feedback again

You are not allowed to post comments on this tracker with your current authentification level.

bug #515: gdbm.h misses sys/types.h include for type off_t

Submitted by:  Rainer Jung <rjung>
Submitted on:  Tue Jun 29 11:35:22 2021  
 
Category: NonePriority: 5 - Normal
Severity: 5 - NormalStatus: Fixed
Privacy: PublicAssigned to: Sergey Poznyakoff <gray>
Open/Closed: Closed

Wed Jul 7 06:41:08 2021, comment #2:

Thanks a lot. I pushed the following to fix it: https://git.gnu.org.ua/gdbm.git/commit/?id=1967040e5

Sergey Poznyakoff <gray>
Project AdministratorIn charge of this item.
Tue Jun 29 11:38:16 2021, comment #1:

This is only relevant for version 1.20. Up until 1.19, type off_t was not used in gdbm.h.

Rainer Jung <rjung>
Tue Jun 29 11:35:22 2021, original submission:

File gdbm.h misses sys/types.h include for type off_t. This leads to compilation errors, e.g. on SuSE Linux Enterprise 11 (SLES 11) and probably other older Linuxes:

gdbm.h:293: error: expected specifier-qualifier-list before 'off_t'

For newer Linux, like SLES 12, included file stdio.h includes

typedef __off_t off_t;

or

typedef __off64_t off_t;

and the types __off_t resp. __off64_t are defined in bits/types.h which is also included by stdio.h.

In old SLES 11 these typdefs aee missing and an inclusion of sys/types.h is needed. That inclusion should be POSIX conforming.

So I suggest to add

#include <sys/types.h>

to gdbm.h.

Thanks and regards,

Rainer

Rainer Jung <rjung>

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by gray (Posted a comment)
  • -unavailable- added by rjung (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    3 latest changes follow.

    Date Changed By Updated Field Previous Value => Replaced By
    Wed Jul 7 06:41:08 2021grayStatusNone=>Fixed
      Assigned toNone=>gray
      Open/ClosedOpen=>Closed
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup+gray