Update to 1.1.20 (RHBZ#2144341)

This commit is contained in:
Li Rui Bin 2022-12-10 21:25:17 +08:00
parent 6a03f89e4e
commit 136175148e
4 changed files with 7 additions and 67 deletions

1
.gitignore vendored
View File

@ -18,3 +18,4 @@ gearmand-0.14.tar.gz
/gearmand-1.1.17.tar.gz
/gearmand-1.1.18.tar.gz
/gearmand-1.1.19.1.tar.gz
/gearmand-1.1.20.tar.gz

View File

@ -1,50 +0,0 @@
From d6507e52adcf851d8888b93f9905f0fad1052af2 Mon Sep 17 00:00:00 2001
From: Robin Lee <cheeselee@fedoraproject.org>
Date: Sun, 16 Feb 2020 02:37:42 +0800
Subject: [PATCH] Fix crashing of tests when '-Wp,-D_GLIBCXX_ASSERTIONS' is
given
If 'vec' is a vector, calling 'vec[0]' will crash the program if
'vec' is empty and '-Wp,-D_GLIBCXX_ASSERTIONS' given in CXXFLAGS.
Fixes https://github.com/gearman/gearmand/issues/272
---
libtest/cmdline.h | 4 ++--
tests/hostile.cc | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/libtest/cmdline.h b/libtest/cmdline.h
index 692363f6..3503bada 100644
--- a/libtest/cmdline.h
+++ b/libtest/cmdline.h
@@ -153,7 +153,7 @@ class Application {
const char* stdout_c_str() const
{
- return &_stdout_buffer[0];
+ return _stdout_buffer.size() ? &_stdout_buffer[0] : NULL;
}
libtest::vchar_t stderr_result() const
@@ -163,7 +163,7 @@ class Application {
const char* stderr_c_str() const
{
- return &_stderr_buffer[0];
+ return _stderr_buffer.size() ? &_stderr_buffer[0] : NULL;
}
size_t stderr_result_length() const
diff --git a/tests/hostile.cc b/tests/hostile.cc
index c4c0487d..c7686206 100644
--- a/tests/hostile.cc
+++ b/tests/hostile.cc
@@ -136,7 +136,7 @@ extern "C" {
gearman_return_t rc;
void *value= gearman_client_do(&client, WORKER_FUNCTION_NAME,
NULL,
- &payload[0],
+ payload.size() ? &payload[0] : NULL,
payload.size() ? random() % payload.size() : 0,
NULL, &rc);

View File

@ -1,5 +1,5 @@
Name: gearmand
Version: 1.1.19.1
Version: 1.1.20
Release: %autorelease
Summary: A distributed job system
@ -10,7 +10,6 @@ Source1: gearmand.init
Source2: gearmand.sysconfig
Source3: gearmand.service
Patch0: gearmand-1.1.12-ppc64le.patch
Patch1: https://github.com/gearman/gearmand/pull/273.patch
# Fails to build on PPC.
# See https://bugzilla.redhat.com/987104 and https://bugzilla.redhat.com/987109
ExcludeArch: ppc
@ -26,10 +25,7 @@ BuildRequires: libmemcached-devel, memcached
# https://src.fedoraproject.org/rpms/libmemcached-awesome/pull-request/1
# libmemcached-awesome-devel needs cyrus-sasl-devel
BuildRequires: cyrus-sasl-devel
%if 0%{?rhel} < 9
# not available in EPEL 9 yet
BuildRequires: hiredis-devel
%endif
BuildRequires: gperf
BuildRequires: mariadb-connector-c-devel openssl-devel
BuildRequires: libpq-devel
@ -37,16 +33,13 @@ BuildRequires: zlib-devel
BuildRequires: systemd
# For %%check
# https://github.com/gearman/gearmand/issues/278
# https://github.com/gearman/gearmand/issues/277
#BuildRequires: curl-devel
# google perftools available only on these
%ifarch %{ix86} x86_64 ppc64 ppc64le aarch64 %{arm}
%if 0%{?rhel} < 9
# not available in EPEL 9 yet
BuildRequires: gperftools-devel
%endif
%endif
BuildRequires: make
Requires(pre): shadow-utils
Requires: procps
@ -81,9 +74,7 @@ Obsoletes: libgearman-1.0-devel < %{version}-%{release}
Development headers for %{name}.
%prep
%setup -q
%patch0 -p1
%patch1 -p1
%autosetup -p1
%build
%configure --disable-static --disable-silent-rules --enable-ssl
@ -103,7 +94,6 @@ install -m 0644 %{SOURCE3} %{buildroot}%{_unitdir}/%{name}.service
%check
# https://github.com/gearman/gearmand/issues/279
# https://github.com/gearman/gearmand/issues/277
#make test
@ -129,7 +119,7 @@ exit 0
%files
%license COPYING
%doc AUTHORS ChangeLog HACKING THANKS
%doc AUTHORS ChangeLog CONTRIBUTING.md README.md THANKS
%config(noreplace) %{_sysconfdir}/sysconfig/gearmand
%{_sbindir}/gearmand
%{_bindir}/gearman
@ -145,8 +135,7 @@ exit 0
%files -n libgearman-devel
%license COPYING
%doc AUTHORS ChangeLog HACKING THANKS
%dir %{_includedir}/libgearman
%doc AUTHORS ChangeLog CONTRIBUTING.md README.md THANKS
%{_includedir}/libgearman/
%{_libdir}/pkgconfig/gearmand.pc
%{_libdir}/libgearman.so

View File

@ -1 +1 @@
SHA512 (gearmand-1.1.19.1.tar.gz) = cbcf85dfd7268aa9acc039eac9505385af3be89eeba48270ddb45739e0ccdcf0d2963d821ccbb6a471396fc9ab2521d096f5d6c2fc3d41b3fb050bd82a795f1f
SHA512 (gearmand-1.1.20.tar.gz) = 461d1c439b3978edb40a60c6ce7c247bb96fde72ef7446d0904eace3b9ff83c80a58276e05ba79414d23b1eebe491af7dee1bebf3655253241baeee4bdc030c3