Bug #11748 mysql.h exports generally-named functions

Submitted: 5 Jul 2005 20:49 Modified: 5 Jul 2005 20:53
Reporter: Timothy Smith Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: Command-line Clients Severity:S4 (Feature request)
Version:all OS:Any (all)
Assigned to: CPU Architecture:Any

[5 Jul 2005 20:49] Timothy Smith
Description:
The file include/my_list.h exports some names that are too generically named.  This can cause name clashes with application functions.

typedef struct st_list {
struct st_list *prev,*next;
void *data;
} LIST;

extern LIST *list_add(LIST *root,LIST *element);
extern LIST *list_delete(LIST *root,LIST *element);
extern LIST *list_cons(void *data,LIST *root);
extern LIST *list_reverse(LIST *root);
extern void list_free(LIST *root,unsigned int free_data);
extern unsigned int list_length(LIST *);
extern int list_walk(LIST *,list_walk_action action,gptr argument);

It would be good to rename these to:

extern MY_LIST *my_list_add(MY_LIST *root, MY_LIST *element);
/* Similar for other list_* functions */

How to repeat:

n/a

Suggested fix:

See Description.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.039 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.