Add function to get library version.

This commit is contained in:
Vreixo Formoso 2008-01-24 21:20:31 +01:00
parent 66c2f9b7b1
commit 7f727979e1
2 changed files with 13 additions and 0 deletions

View File

@ -745,6 +745,11 @@ void iso_finish();
*/ */
int iso_image_new(const char *name, IsoImage **image); int iso_image_new(const char *name, IsoImage **image);
/**
* Get version of the libisofs library.
*/
void iso_lib_version(int *major, int *minor, int *micro);
/** /**
* Create a burn_source to actually write the image. That burn_source can be * Create a burn_source to actually write the image. That burn_source can be
* used with libburn as a data source for a track. * used with libburn as a data source for a track.

View File

@ -9,6 +9,7 @@
#include "util.h" #include "util.h"
#include "error.h" #include "error.h"
#include "../version.h"
#include <stdlib.h> #include <stdlib.h>
#include <wchar.h> #include <wchar.h>
@ -1172,3 +1173,10 @@ char *ucs2str(const char *buf, size_t len)
out[len] = '\0'; out[len] = '\0';
return strdup(out); return strdup(out);
} }
void iso_lib_version(int *major, int *minor, int *micro)
{
*major = LIBISOFS_MAJOR_VERSION;
*minor = LIBISOFS_MINOR_VERSION;
*micro = LIBISOFS_MICRO_VERSION;
}