Release V0.2.4
This commit is contained in:
commit
dd68aceac9
3
NEWS
3
NEWS
|
@ -1,5 +1,8 @@
|
||||||
Copyright (C) 2014 Tim Ruehsen
|
Copyright (C) 2014 Tim Ruehsen
|
||||||
|
|
||||||
|
30.05.2014
|
||||||
|
* Fixed psl_builtin() to return NULL if no built-in PSL data is available
|
||||||
|
|
||||||
27.05.2014 Release V0.2.3
|
27.05.2014 Release V0.2.3
|
||||||
* changed API version to 0.2
|
* changed API version to 0.2
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
|
|
||||||
AC_INIT([libpsl], [0.2.3], [tim.ruehsen@gmx.de], [libpsl], [http://github.com/rockdaboot/libpsl])
|
AC_INIT([libpsl], [0.2.4], [tim.ruehsen@gmx.de], [libpsl], [http://github.com/rockdaboot/libpsl])
|
||||||
AC_PREREQ([2.59])
|
AC_PREREQ([2.59])
|
||||||
AM_INIT_AUTOMAKE([1.10 -Wall no-define])
|
AM_INIT_AUTOMAKE([1.10 -Wall no-define])
|
||||||
|
|
||||||
|
@ -63,7 +63,7 @@ AS_IF([ test "$enable_man" != no ], [
|
||||||
# 4. If any interfaces have been added, removed, or changed since the last update, increment current, and set revision to 0.
|
# 4. If any interfaces have been added, removed, or changed since the last update, increment current, and set revision to 0.
|
||||||
# 5. If any interfaces have been added since the last public release, then increment age.
|
# 5. If any interfaces have been added since the last public release, then increment age.
|
||||||
# 6. If any interfaces have been removed or changed since the last public release, then set age to 0.
|
# 6. If any interfaces have been removed or changed since the last public release, then set age to 0.
|
||||||
AC_SUBST([LIBPSL_SO_VERSION], [0:3:0])
|
AC_SUBST([LIBPSL_SO_VERSION], [0:4:0])
|
||||||
AC_SUBST([LIBPSL_API_VERSION], [0.2])
|
AC_SUBST([LIBPSL_API_VERSION], [0.2])
|
||||||
|
|
||||||
# Check for idn2
|
# Check for idn2
|
||||||
|
|
|
@ -557,7 +557,11 @@ void psl_free(psl_ctx_t *psl)
|
||||||
*/
|
*/
|
||||||
const psl_ctx_t *psl_builtin(void)
|
const psl_ctx_t *psl_builtin(void)
|
||||||
{
|
{
|
||||||
|
#ifdef WITH_BUILTIN
|
||||||
return &_builtin_psl;
|
return &_builtin_psl;
|
||||||
|
#else
|
||||||
|
return NULL;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
10
tools/psl.c
10
tools/psl.c
|
@ -90,7 +90,8 @@ int main(int argc, const char *const *argv)
|
||||||
fprintf(stderr, "Dropped data from %s\n", psl_file);
|
fprintf(stderr, "Dropped data from %s\n", psl_file);
|
||||||
psl_file = NULL;
|
psl_file = NULL;
|
||||||
}
|
}
|
||||||
psl = (psl_ctx_t *) psl_builtin();
|
if (!(psl = (psl_ctx_t *) psl_builtin()))
|
||||||
|
printf("No builtin PSL data available\n");
|
||||||
}
|
}
|
||||||
else if (!strcmp(*arg, "--load-psl-file") && arg < argv + argc - 1) {
|
else if (!strcmp(*arg, "--load-psl-file") && arg < argv + argc - 1) {
|
||||||
psl_free(psl);
|
psl_free(psl);
|
||||||
|
@ -118,6 +119,11 @@ int main(int argc, const char *const *argv)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!psl && mode != 99) {
|
||||||
|
printf("No PSL data available - aborting\n");
|
||||||
|
exit(2);
|
||||||
|
}
|
||||||
|
|
||||||
if (mode == 1) {
|
if (mode == 1) {
|
||||||
for (; arg < argv + argc; arg++)
|
for (; arg < argv + argc; arg++)
|
||||||
printf("%s: %d\n", *arg, psl_is_public_suffix(psl, *arg));
|
printf("%s: %d\n", *arg, psl_is_public_suffix(psl, *arg));
|
||||||
|
@ -135,7 +141,7 @@ int main(int argc, const char *const *argv)
|
||||||
printf("%s: %d\n", *arg, psl_is_cookie_domain_acceptable(psl, *arg, cookie_domain));
|
printf("%s: %d\n", *arg, psl_is_cookie_domain_acceptable(psl, *arg, cookie_domain));
|
||||||
}
|
}
|
||||||
else if (mode == 99) {
|
else if (mode == 99) {
|
||||||
if (psl != psl_builtin()) {
|
if (psl && psl != psl_builtin()) {
|
||||||
printf("suffixes: %d\n", psl_suffix_count(psl));
|
printf("suffixes: %d\n", psl_suffix_count(psl));
|
||||||
printf("exceptions: %d\n", psl_suffix_exception_count(psl));
|
printf("exceptions: %d\n", psl_suffix_exception_count(psl));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue