Compare commits
4 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
fd651725ba | ||
|
|
93c123906d | ||
|
|
8072b1351c | ||
|
|
aeb2b60711 |
4 changed files with 29 additions and 22 deletions
0
.cvsignore → .gitignore
vendored
0
.cvsignore → .gitignore
vendored
21
Makefile
21
Makefile
|
|
@ -1,21 +0,0 @@
|
||||||
# Makefile for source rpm: adns
|
|
||||||
# $Id: Makefile,v 1.1 2004/11/08 04:00:44 cvsextras Exp $
|
|
||||||
NAME := adns
|
|
||||||
SPECFILE = $(firstword $(wildcard *.spec))
|
|
||||||
|
|
||||||
define find-makefile-common
|
|
||||||
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
|
|
||||||
endef
|
|
||||||
|
|
||||||
MAKEFILE_COMMON := $(shell $(find-makefile-common))
|
|
||||||
|
|
||||||
ifeq ($(MAKEFILE_COMMON),)
|
|
||||||
# attept a checkout
|
|
||||||
define checkout-makefile-common
|
|
||||||
test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2
|
|
||||||
endef
|
|
||||||
|
|
||||||
MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
|
|
||||||
endif
|
|
||||||
|
|
||||||
include $(MAKEFILE_COMMON)
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
Name: adns
|
Name: adns
|
||||||
Version: 1.4
|
Version: 1.4
|
||||||
Release: 5%{?dist}
|
Release: 6%{?dist}
|
||||||
|
|
||||||
Summary: Advanced, easy to use, asynchronous-capable DNS client library
|
Summary: Advanced, easy to use, asynchronous-capable DNS client library
|
||||||
|
|
||||||
|
|
@ -11,6 +11,8 @@ Source0: ftp://ftp.chiark.greenend.org.uk/users/ian/adns/%{name}-%{versio
|
||||||
BuildRequires: autoconf
|
BuildRequires: autoconf
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||||
|
|
||||||
|
Patch0: adns14-rh514838.patch
|
||||||
|
|
||||||
%description
|
%description
|
||||||
adns is a resolver library for C (and C++) programs. In contrast with
|
adns is a resolver library for C (and C++) programs. In contrast with
|
||||||
the existing interfaces, gethostbyname et al and libresolv, it has the
|
the existing interfaces, gethostbyname et al and libresolv, it has the
|
||||||
|
|
@ -69,6 +71,8 @@ programs for use from the command line and in scripts:
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
|
|
||||||
|
%patch0 -p1 -b .rh514838
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%ifarch sparcv9 sparc64 s390 s390x
|
%ifarch sparcv9 sparc64 s390 s390x
|
||||||
export CFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE -fPIC"
|
export CFLAGS="$RPM_OPT_FLAGS -D_GNU_SOURCE -fPIC"
|
||||||
|
|
@ -111,6 +115,9 @@ rm -fr $RPM_BUILD_ROOT
|
||||||
%attr(755,root,root) %{_bindir}/*
|
%attr(755,root,root) %{_bindir}/*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Aug 06 2009 Adam Tkac <atkac redhat com> 1.4-6
|
||||||
|
- don't crash in adns_strerror if parameter is unknown error code (#514838)
|
||||||
|
|
||||||
* Mon Feb 23 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.4-5
|
* Mon Feb 23 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.4-5
|
||||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
|
||||||
|
|
||||||
|
|
|
||||||
21
adns14-rh514838.patch
Normal file
21
adns14-rh514838.patch
Normal file
|
|
@ -0,0 +1,21 @@
|
||||||
|
diff -up adns-1.4/src/general.c.rh514838 adns-1.4/src/general.c
|
||||||
|
--- adns-1.4/src/general.c.rh514838 2006-04-08 16:36:57.000000000 +0200
|
||||||
|
+++ adns-1.4/src/general.c 2009-08-06 13:55:06.752562767 +0200
|
||||||
|
@@ -267,6 +267,8 @@ static const struct sinfo {
|
||||||
|
SINFO( nodata, "No such data" )
|
||||||
|
};
|
||||||
|
|
||||||
|
+static const char *unknown_error_str = "unknown error code";
|
||||||
|
+
|
||||||
|
static int si_compar(const void *key, const void *elem) {
|
||||||
|
const adns_status *st= key;
|
||||||
|
const struct sinfo *si= elem;
|
||||||
|
@@ -283,7 +285,7 @@ const char *adns_strerror(adns_status st
|
||||||
|
const struct sinfo *si;
|
||||||
|
|
||||||
|
si= findsinfo(st);
|
||||||
|
- return si->string;
|
||||||
|
+ return (si == NULL) ? unknown_error_str : si->string;
|
||||||
|
}
|
||||||
|
|
||||||
|
const char *adns_errabbrev(adns_status st) {
|
||||||
Loading…
Add table
Add a link
Reference in a new issue