Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package libeconf for openSUSE:Factory checked in at 2022-12-07 17:33:03 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/libeconf (Old) and /work/SRC/openSUSE:Factory/.libeconf.new.1835 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "libeconf" Wed Dec 7 17:33:03 2022 rev:18 rq:1040181 version:0.5.0 Changes: -------- --- /work/SRC/openSUSE:Factory/libeconf/libeconf.changes 2022-11-27 12:52:49.755137350 +0100 +++ /work/SRC/openSUSE:Factory/.libeconf.new.1835/libeconf.changes 2022-12-07 17:33:07.999937367 +0100 @@ -1,0 +2,12 @@ +Fri Dec 02 14:13:24 UTC 2022 - sch...@suse.com + +- Update to version 0.5.0: + * API calls econf_read*WithCallback supporting a general (void *) + argument for user defined data with which the callback function is + called. + * Tagged following functions deprecated: + econf_requireOwner, econf_requireGroup, econf_requirePermissions, + econf_followSymlinks, econf_reset_security_settings + Use one of the econf_read*WithCallback functions instead. + +------------------------------------------------------------------- Old: ---- libeconf-0.4.9.tar.xz New: ---- libeconf-0.5.0.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ libeconf.spec ++++++ --- /var/tmp/diff_new_pack.UINIak/_old 2022-12-07 17:33:08.583940565 +0100 +++ /var/tmp/diff_new_pack.UINIak/_new 2022-12-07 17:33:08.587940587 +0100 @@ -18,7 +18,7 @@ %define lname libeconf0 Name: libeconf -Version: 0.4.9 +Version: 0.5.0 Release: 0 Summary: Enhanced config file parser ala systemd License: LGPL-2.1-or-later ++++++ _service ++++++ --- /var/tmp/diff_new_pack.UINIak/_old 2022-12-07 17:33:08.619940762 +0100 +++ /var/tmp/diff_new_pack.UINIak/_new 2022-12-07 17:33:08.623940784 +0100 @@ -1,6 +1,6 @@ <services> <service name="tar_scm" mode="disabled"> - <param name="version">0.4.9</param> + <param name="version">0.5.0</param> <param name="versionformat">@PARENT_TAG@</param> <param name="versionrewrite-pattern">v(\d+\.\d+\.\d+)</param> <param name="url">https://github.com/openSUSE/libeconf.git</param> ++++++ _servicedata ++++++ --- /var/tmp/diff_new_pack.UINIak/_old 2022-12-07 17:33:08.643940894 +0100 +++ /var/tmp/diff_new_pack.UINIak/_new 2022-12-07 17:33:08.647940915 +0100 @@ -1,7 +1,7 @@ <servicedata> <service name="tar_scm"> <param name="url">https://github.com/openSUSE/libeconf.git</param> - <param name="changesrevision">3f363ba03817b337c75bb411a8f561a59751cb56</param> + <param name="changesrevision">40d70bbe6ebf992082d8c83df522ec9e36364a1b</param> </service> </servicedata> (No newline at EOF) ++++++ libeconf-0.4.9.tar.xz -> libeconf-0.5.0.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libeconf-0.4.9/CMakeLists.txt new/libeconf-0.5.0/CMakeLists.txt --- old/libeconf-0.4.9/CMakeLists.txt 2022-11-23 13:45:05.000000000 +0100 +++ new/libeconf-0.5.0/CMakeLists.txt 2022-12-02 14:39:03.000000000 +0100 @@ -3,7 +3,7 @@ # Ensure built-in policies from CMake are used, (e.g. improved policies for macOS) cmake_policy(VERSION ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION}) -project(libeconf VERSION 0.4.9 +project(libeconf VERSION 0.5.0 DESCRIPTION "Enhanced config file parser, which merges config files placed in several locations into one." LANGUAGES C ) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libeconf-0.4.9/NEWS new/libeconf-0.5.0/NEWS --- old/libeconf-0.4.9/NEWS 2022-11-23 13:45:05.000000000 +0100 +++ new/libeconf-0.5.0/NEWS 2022-12-02 14:39:03.000000000 +0100 @@ -1,3 +1,12 @@ +Version 0.5.0 +* API calls econf_read*WithCallback supporting a general (void *) + argument for user defined data with which the callback function is + called. +* Tagged following functions deprecated: + econf_requireOwner, econf_requireGroup, econf_requirePermissions, + econf_followSymlinks, econf_reset_security_settings + Use one of the econf_read*WithCallback functions instead. + Version 0.4.9 * new API calls: ** econf_readFileWithCallback diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libeconf-0.4.9/doc/man/libeconf.3 new/libeconf-0.5.0/doc/man/libeconf.3 --- old/libeconf-0.4.9/doc/man/libeconf.3 2022-11-23 13:45:05.000000000 +0100 +++ new/libeconf-0.5.0/doc/man/libeconf.3 2022-12-02 14:39:03.000000000 +0100 @@ -115,7 +115,7 @@ .br .RI "Process the file of the given file_name and save its contents into key_file object\&. " .ti -1c -.RI "\fBeconf_err\fP \fBeconf_readFileWithCallback\fP (\fBeconf_file\fP **result, const char *file_name, const char *delim, const char *comment, bool (*callback)(const char *filename))" +.RI "\fBeconf_err\fP \fBeconf_readFileWithCallback\fP (\fBeconf_file\fP **result, const char *file_name, const char *delim, const char *comment, bool (*callback)(const char *filename, const void *data), const void *callback_data)" .br .RI "Has the same functionality like \fBeconf_readFile\fP. The user can additionally define a callback in order to check the parsed file\&. " .ti -1c @@ -127,7 +127,7 @@ .br .RI "Evaluating key/values of a given configuration by reading and merging all needed/available files in two different directories (normally in /usr/etc and /etc)\&. " .ti -1c -.RI "\fBeconf_err\fP \fBeconf_readDirsWithCallback\fP (\fBeconf_file\fP **key_file, const char *usr_conf_dir, const char *etc_conf_dir, const char *project_name, const char *config_suffix, const char *delim, const char *comment, bool (*callback)(const char *filename))" +.RI "\fBeconf_err\fP \fBeconf_readDirsWithCallback\fP (\fBeconf_file\fP **key_file, const char *usr_conf_dir, const char *etc_conf_dir, const char *project_name, const char *config_suffix, const char *delim, const char *comment, bool (*callback)(const char *filename, const void *data), const void *callback_data)" .br .RI "Has the same functionality like \fBeconf_readDirs\fP. The user can additionally define a callback in order e.g. to check all parsed file\&. " .ti -1c @@ -135,7 +135,7 @@ .br .RI "Evaluating key/values for every given configuration files in two different directories (normally in /usr/etc and /etc)\&. " .ti -1c -.RI "\fBeconf_err\fP \fBeconf_readDirsHistoryWithCallback\fP (\fBeconf_file\fP ***key_files, size_t *size, const char *usr_conf_dir, const char *etc_conf_dir, const char *project_name, const char *config_suffix, const char *delim, const char *comment, bool (*callback)(const char *filename))" +.RI "\fBeconf_err\fP \fBeconf_readDirsHistoryWithCallback\fP (\fBeconf_file\fP ***key_files, size_t *size, const char *usr_conf_dir, const char *etc_conf_dir, const char *project_name, const char *config_suffix, const char *delim, const char *comment, bool (*callback)(const char *filename, const void *data), const void *callback_data)" .br .RI "Has the same functionality like \fBeconf_readDirsHistory\fP. The user can additionally define a callback in order e.g. to check all parsed file\&. " .ti -1c @@ -275,26 +275,6 @@ .br .RI "Free memory allocated by e\&.g\&. " .ti -1c -.RI "void \fBeconf_requireOwner\fP (uid_t owner)" -.br -.RI "All parsed files require this user permission\&. " -.ti -1c -.RI "void \fBeconf_requireGroup\fP (gid_t group)" -.br -.RI "All parsed files require this group permission\&. " -.ti -1c -.RI "void \fBeconf_requirePermissions\fP (mode_t file_perms, mode_t dir_perms)" -.br -.RI "All parsed file have to have these file and directory permissions\&. " -.ti -1c -.RI "void \fBeconf_followSymlinks\fP (bool allow)" -.br -.RI "Allowing the parser to follow sym links (default: true)\&. " -.ti -1c -.RI "void \fBeconf_reset_security_settings\fP (void)" -.br -.RI "Reset all UID, GID, permissions,\&.\&.\&. " -.ti -1c .RI "char \fBeconf_comment_tag\fP (\fBeconf_file\fP *key_file)" .br .RI "Returns the comment character tag of the given econf_file object\&. " @@ -477,7 +457,7 @@ .PP Default behaviour if entries have the same name in one file: The first hit will be returned\&. Further entries will be ignored\&. This can be changed by setting the environment variable ECONF_JOIN_SAME_ENTRIES\&. In that case entries with the same name will be joined to one single entry\&. -.SS "\fBeconf_err\fP econf_readFileWithCallback (\fBeconf_file\fP ** result, const char * file_name, const char * delim, const char * comment, bool (*callback)(const char *filename))" +.SS "\fBeconf_err\fP econf_readFileWithCallback (\fBeconf_file\fP ** result, const char * file_name, const char * delim, const char * comment, bool (*callback)(const char *filename, const void *data), const void *callback_data)" .PP Process the file of the given file_name and save its contents into key_file object\&. The user defined function will be called in order e.g. to check the correct file permissions\&. @@ -493,6 +473,8 @@ \fIcomment\fP array of characters which define the start of a comment .br \fIcallback\fP function which will be called for the given filename\&. This user defined function has the pathname as paramter and returns true if this file can be parsed\&. If not, the parsing will be aborted and ECONF_PARSING_CALLBACK_FAILED will be returned\&. +.br +\fIcallback_data\fP pointer which will be given to the callback function. .RE .PP \fBReturns:\fP @@ -504,7 +486,7 @@ .PP .nf #include "libeconf.h" -bool checkFile(const char *filename) { +bool checkFile(const char *filename, const void *data) { /* checking code which returns true or false */ return true; } @@ -512,7 +494,7 @@ econf_file *key_file = NULL; econf_err error; -error = econf_readFileWithCallback (&key_file, "/etc/test.conf", "=", "#", checkFile); +error = econf_readFileWithCallback (&key_file, "/etc/test.conf", "=", "#", checkFile, NULL); econf_free (key_file); .fi .PP @@ -604,7 +586,7 @@ .fi .PP -.SS "\fBeconf_err\fP econf_readDirsWithCallback (\fBeconf_file\fP ** key_file, const char * usr_conf_dir, const char * etc_conf_dir, const char * project_name, const char * config_suffix, const char * delim, const char * comment, bool (*callback)(const char *filename))" +.SS "\fBeconf_err\fP econf_readDirsWithCallback (\fBeconf_file\fP ** key_file, const char * usr_conf_dir, const char * etc_conf_dir, const char * project_name, const char * config_suffix, const char * delim, const char * comment, bool (*callback)(const char *filename, const void *data), const void *callback_data)" .PP Evaluating the content of a given configuration file by reading all needed/available files in two different directories (normally in /usr/etc and /etc)\&. For each parsed file the user defined function will be called in order e.g. to check the correct file permissions\&. @@ -626,6 +608,8 @@ \fIcomment\fP array of characters which define the start of a comment .br \fIcallback\fP function which will be called for each file\&. This user defined function has the pathname as paramter and returns true if this file can be parsed\&. If not, the parsing of all files will be aborted and ECONF_PARSING_CALLBACK_FAILED will be returned\&. +.br +\fIcallback_data\fP pointer which will be given to the callback function. .RE .PP \fBReturns:\fP @@ -638,7 +622,7 @@ .nf #include "libeconf.h" -bool checkFile(const char *filename) { +bool checkFile(const char *filename, const void *data) { /* checking code which returns true or false */ return true; } @@ -652,7 +636,8 @@ "example", "conf", "=", "#", - checkFile); + checkFile, + NULL); econf_free (key_file); .fi @@ -688,7 +673,7 @@ .RE .PP -.SS "\fBeconf_err\fP econf_readDirsHistoryWithCallback (\fBeconf_file\fP *** key_files, size_t * size, const char * usr_conf_dir, const char * etc_conf_dir, const char * project_name, const char * config_suffix, const char * delim, const char * comment, bool (*callback)(const char *filename))" +.SS "\fBeconf_err\fP econf_readDirsHistoryWithCallback (\fBeconf_file\fP *** key_files, size_t * size, const char * usr_conf_dir, const char * etc_conf_dir, const char * project_name, const char * config_suffix, const char * delim, const char * comment, bool (*callback)(const char *filename, const void *data), const void *callback_data)" .PP Evaluating key/values for every given configuration files in two different directories (normally in /usr/etc and /etc)\&. For each parsed file the user defined function will be called in order e.g. to check the correct file permissions\&. Returns a list of read configuration files and their values\&. @@ -712,6 +697,8 @@ \fIcomment\fP array of characters which define the start of a comment .br \fIcallback\fP function which will be called for each file\&. This user defined function has the pathname as paramter and returns true if this file can be parsed\&. If not, the parsing of all files will be aborted and ECONF_PARSING_CALLBACK_FAILED will be returned\&. +.br +\fIcallback_data\fP pointer which will be given to the callback function. .RE .PP \fBReturns:\fP @@ -1439,83 +1426,6 @@ .RE .PP -.SS "void econf_requireOwner (uid_t owner)" - -.PP -All parsed files require this user permission\&. -.PP -\fBParameters:\fP -.RS 4 -\fIowner\fP User ID -.RE -.PP -\fBReturns:\fP -.RS 4 -void -.RE -.PP - -.SS "void econf_requireGroup (gid_t group)" - -.PP -All parsed files require this group permission\&. -.PP -\fBParameters:\fP -.RS 4 -\fIgroup\fP Group ID -.RE -.PP -\fBReturns:\fP -.RS 4 -void -.RE -.PP - -.SS "void econf_requirePermissions (mode_t file_perms, mode_t dir_perms)" - -.PP -All parsed file have to have these file and directory permissions\&. -.PP -\fBParameters:\fP -.RS 4 -\fIfile_perms\fP file permissions -.br -\fIdir_perms\fP dir permissions -.RE -.PP -\fBReturns:\fP -.RS 4 -void -.RE -.PP - -.SS "void econf_followSymlinks (bool allow)" - -.PP -Allowing the parser to follow sym links (default: true)\&. -.PP -\fBParameters:\fP -.RS 4 -\fIallow\fP allow to follow sym links\&. -.RE -.PP -\fBReturns:\fP -.RS 4 -void -.RE -.PP - -.SS "void econf_reset_security_settings (void)" - -.PP -Reset all UID, GID, permissions,\&.\&.\&. restrictions for parsed files/dirs\&. -.PP -\fBReturns:\fP -.RS 4 -void -.RE -.PP - .SS "char econf_comment_tag (\fBeconf_file\fP * key_file)" .PP diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libeconf-0.4.9/include/libeconf.h new/libeconf-0.5.0/include/libeconf.h --- old/libeconf-0.4.9/include/libeconf.h 2022-11-23 13:45:05.000000000 +0100 +++ new/libeconf-0.5.0/include/libeconf.h 2022-12-02 14:39:03.000000000 +0100 @@ -166,13 +166,14 @@ * @param callback function which will be called for the given filename. This user defined function has * the pathname as paramter and returns true if this file can be parsed. If not, the * parsing will be aborted and ECONF_PARSING_CALLBACK_FAILED will be returned. + * @param callback_data pointer which will be given to the callback function. * @return econf_err ECONF_SUCCESS or error code * * Usage: * @code * #include "libeconf.h" * - * bool checkFile(const char *filename) { + * bool checkFile(const char *filename, const void *data) { * - checking code which returns true or false - * return true; * } @@ -180,7 +181,7 @@ * econf_file *key_file = NULL; * econf_err error; * - * error = econf_readFileWithCallback (&key_file, "/etc/test.conf", "=", "#", checkFile); + * error = econf_readFileWithCallback (&key_file, "/etc/test.conf", "=", "#", checkFile, NULL); * * econf_free (key_file); * @endcode @@ -193,7 +194,8 @@ */ extern econf_err econf_readFileWithCallback(econf_file **result, const char *file_name, const char *delim, const char *comment, - bool (*callback)(const char *filename)); + bool (*callback)(const char *filename, const void *data), + const void *callback_data); /** @brief Merge the contents of two key_files objects. Entries in etc_file will be * prefered. @@ -284,13 +286,14 @@ * @param callback function which will be called for each file. This user defined function has the * pathname as paramter and returns true if this file can be parsed. If not, the parsing of * all files will be aborted and ECONF_PARSING_CALLBACK_FAILED will be returned. + * @param callback_data pointer which will be given to the callback function. * @return econf_err ECONF_SUCCESS or error code * * Example: Reading content of example.conf in /usr/etc and /etc directory. * @code * #include "libeconf.h" * - * bool checkFile(const char *filename) { + * bool checkFile(const char *filename, const void *data) { * - checking code which returns true or false - * return true; * } @@ -304,7 +307,8 @@ * "example", * "conf", * "=", "#", - * checkFile); + * checkFile, + * NULL); * * econf_free (key_file); * @endcode @@ -317,7 +321,8 @@ const char *config_suffix, const char *delim, const char *comment, - bool (*callback)(const char *filename)); + bool (*callback)(const char *filename, const void *data), + const void *callback_data); /** @brief Evaluating key/values for every given configuration files in two different * directories (normally in /usr/etc and /etc). Returns a list of read configuration @@ -365,6 +370,7 @@ * @param callback function which will be called for each file. This user defined function has the * pathname as paramter and returns true if this file can be parsed. If not, the parsing of * all files will be aborted and ECONF_PARSING_CALLBACK_FAILED will be returned. + * @param callback_data pointer which will be given to the callback function. * @return econf_err ECONF_SUCCESS or error code * */ @@ -376,7 +382,8 @@ const char *config_suffix, const char *delim, const char *comment, - bool (*callback)(const char *filename)); + bool (*callback)(const char *filename, const void *data), + const void *callback_data); /* The API/ABI of the following three functions (econf_newKeyFile, econf_newIniFile and econf_writeFile) are not stable and will change */ @@ -808,44 +815,64 @@ extern void econf_freeFile(econf_file *key_file); /** @brief All parsed files require this user permission. + * DEPRECATED: Use the callback in econf_readFileWithCallback, + * econf_readDirsWithCallback or econf_readDirsHistoryWithCallback + * instead. * * @param owner User ID * @return void * */ -extern void econf_requireOwner(uid_t owner); +extern void __attribute__ ((deprecated("use one of econf_read*WithCallback instead"))) +econf_requireOwner(uid_t owner); /** @brief All parsed files require this group permission. + * DEPRECATED: Use the callback in econf_readFileWithCallback, + * econf_readDirsWithCallback or econf_readDirsHistoryWithCallback + * instead. * * @param group Group ID * @return void * */ -extern void econf_requireGroup(gid_t group); +extern void __attribute__ ((deprecated("use one of econf_read*WithCallback instead"))) +econf_requireGroup(gid_t group); /** @brief All parsed file have to have these file and directory permissions. + * DEPRECATED: Use the callback in econf_readFileWithCallback, + * econf_readDirsWithCallback or econf_readDirsHistoryWithCallback + * instead. * * @param file_perms file permissions * @param dir_perms dir permissions * @return void * */ -extern void econf_requirePermissions(mode_t file_perms, mode_t dir_perms); +extern void __attribute__ ((deprecated("use one of econf_read*WithCallback instead"))) +econf_requirePermissions(mode_t file_perms, mode_t dir_perms); /** @brief Allowing the parser to follow sym links (default: true). + * DEPRECATED: Use the callback in econf_readFileWithCallback, + * econf_readDirsWithCallback or econf_readDirsHistoryWithCallback + * instead. * * @param allow allow to follow sym links. * @return void * */ -extern void econf_followSymlinks(bool allow); +extern void __attribute__ ((deprecated("use one of econf_read*WithCallback instead"))) +econf_followSymlinks(bool allow); /** @brief Reset all UID, GID, permissions,... restrictions for parsed files/dirs. + * DEPRECATED: Use the callback in econf_readFileWithCallback, + * econf_readDirsWithCallback or econf_readDirsHistoryWithCallback + * instead. * * @return void * */ -extern void econf_reset_security_settings(void); +extern void __attribute__ ((deprecated("use one of econf_read*WithCallback instead"))) +econf_reset_security_settings(void); #ifdef __cplusplus } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libeconf-0.4.9/lib/libeconf.c new/libeconf-0.5.0/lib/libeconf.c --- old/libeconf-0.4.9/lib/libeconf.c 2022-11-23 13:45:05.000000000 +0100 +++ new/libeconf-0.5.0/lib/libeconf.c 2022-12-02 14:39:03.000000000 +0100 @@ -138,7 +138,8 @@ // Process the file of the given file_name and save its contents into key_file econf_err econf_readFileWithCallback(econf_file **key_file, const char *file_name, const char *delim, const char *comment, - bool (*callback)(const char *filename)) + bool (*callback)(const char *filename, const void *data), + const void *callback_data) { econf_err t_err; struct stat sb; @@ -169,7 +170,7 @@ } // calling user defined checks - if (callback != NULL && !(*callback)(file_name)) + if (callback != NULL && !(*callback)(file_name, callback_data)) return ECONF_PARSING_CALLBACK_FAILED; // Get absolute path if not provided @@ -206,7 +207,7 @@ econf_err econf_readFile(econf_file **key_file, const char *file_name, const char *delim, const char *comment) { - return econf_readFileWithCallback(key_file, file_name, delim, comment, NULL); + return econf_readFileWithCallback(key_file, file_name, delim, comment, NULL, NULL); } // Merge the contents of two key files @@ -257,7 +258,8 @@ const char *config_suffix, const char *delim, const char *comment, - bool (*callback)(const char *filename)) + bool (*callback)(const char *filename, const void *data), + const void *callback_data) { const char *suffix, *default_dirs[3] = {NULL, NULL, NULL}; char *distfile, *etcfile, *cp; @@ -314,7 +316,8 @@ if (etcfile) { - error = econf_readFileWithCallback(&key_file, etcfile, delim, comment, callback); + error = econf_readFileWithCallback(&key_file, etcfile, delim, comment, + callback, callback_data); if (error && error != ECONF_NOFILE) return error; } @@ -328,7 +331,8 @@ and merge all *.d files. */ if (distfile) { - error = econf_readFileWithCallback(&key_file, distfile, delim, comment, callback); + error = econf_readFileWithCallback(&key_file, distfile, delim, comment, + callback, callback_data); if (error && error != ECONF_NOFILE) return error; } @@ -410,7 +414,7 @@ const char *comment) { return econf_readDirsHistoryWithCallback(key_files, size, dist_conf_dir, etc_conf_dir, project_name, - config_suffix, delim, comment, NULL); + config_suffix, delim, comment, NULL, NULL); } econf_err econf_readDirsWithCallback(econf_file **result, @@ -420,7 +424,8 @@ const char *config_suffix, const char *delim, const char *comment, - bool (*callback)(const char *filename)) + bool (*callback)(const char *filename, const void *data), + const void *callback_data) { size_t size = 0; econf_file **key_files; @@ -434,7 +439,8 @@ config_suffix, delim, comment, - callback); + callback, + callback_data); if (error != ECONF_SUCCESS) return error; @@ -455,7 +461,7 @@ { return econf_readDirsWithCallback(result, dist_conf_dir, etc_conf_dir, project_name, config_suffix, delim, - comment, NULL); + comment, NULL, NULL); } // Write content of a econf_file struct to specified location diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libeconf-0.4.9/lib/libeconf.map new/libeconf-0.5.0/lib/libeconf.map --- old/libeconf-0.4.9/lib/libeconf.map 2022-11-23 13:45:05.000000000 +0100 +++ new/libeconf-0.5.0/lib/libeconf.map 2022-12-02 14:39:03.000000000 +0100 @@ -66,3 +66,9 @@ econf_readDirsWithCallback; econf_readDirsHistoryWithCallback; } LIBECONF_0.3; +LIBECONF_0.5 { + global: + econf_readFileWithCallback; + econf_readDirsWithCallback; + econf_readDirsHistoryWithCallback; +} LIBECONF_0.4; \ No newline at end of file diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libeconf-0.4.9/meson.build new/libeconf-0.5.0/meson.build --- old/libeconf-0.4.9/meson.build 2022-11-23 13:45:05.000000000 +0100 +++ new/libeconf-0.5.0/meson.build 2022-12-02 14:39:03.000000000 +0100 @@ -7,7 +7,7 @@ 'b_pie=true', 'warning_level=3',], license : 'MIT', - version : '0.4.9', + version : '0.5.0', ) cc = meson.get_compiler('c') diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libeconf-0.4.9/tests/tst-checkfiles.c new/libeconf-0.5.0/tests/tst-checkfiles.c --- old/libeconf-0.4.9/tests/tst-checkfiles.c 2022-11-23 13:45:05.000000000 +0100 +++ new/libeconf-0.5.0/tests/tst-checkfiles.c 2022-12-02 14:39:03.000000000 +0100 @@ -7,15 +7,17 @@ #include <unistd.h> #include <sys/stat.h> #include "libeconf.h" -bool checkLink(const char *filename); +bool checkLink(const char *filename, const void *data); /* Test case: * Using user defined callback for checking files which will be parsed. */ - bool checkLink(const char *filename) { +bool checkLink(const char *filename, const void *data) { struct stat sb; + fprintf (stderr,"Given string: -%s-\n", (const char*)data); + if (lstat(filename, &sb) == -1 || (sb.st_mode&S_IFMT) == S_IFLNK) return false; @@ -28,15 +30,14 @@ econf_file *key_file = NULL; econf_err error; - /* checking not allowed links*/ if (symlink(TESTSDIR"tst-arguments-string/etc/arguments.conf", TESTSDIR"tst-arguments-string/etc/link.conf") == -1) { fprintf (stderr, "ERROR: cannot create sym link: %s\n", TESTSDIR"tst-arguments-string/etc/link.conf"); return 1; } - - error = econf_readFileWithCallback (&key_file, TESTSDIR"tst-arguments-string/etc/link.conf", "=", "#", checkLink); + error = econf_readFileWithCallback (&key_file, TESTSDIR"tst-arguments-string/etc/link.conf", "=", "#", + checkLink, (void *) "test"); remove(TESTSDIR"tst-arguments-string/etc/link.conf"); if (error != ECONF_PARSING_CALLBACK_FAILED) {