Hello community,

here is the log from the commit of package corosync for openSUSE:Factory 
checked in at 2018-04-22 14:34:39
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/corosync (Old)
 and      /work/SRC/openSUSE:Factory/.corosync.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "corosync"

Sun Apr 22 14:34:39 2018 rev:57 rq:598465 version:2.4.4

Changes:
--------
--- /work/SRC/openSUSE:Factory/corosync/corosync.changes        2018-04-17 
11:13:22.706056309 +0200
+++ /work/SRC/openSUSE:Factory/.corosync.new/corosync.changes   2018-04-22 
14:34:42.503674637 +0200
@@ -1,0 +2,78 @@
+Tue Apr 17 10:19:52 UTC 2018 - b...@suse.com
+
+- corosync-2.4.4 is available now(bsc#1089836)
+      man:fix in corosync-qdevice.8
+      quorumtool: remove duplicated help message
+      cfg: nodeid should be unsigned int
+      coroparse: Use readdir instead of readdir_r
+      wd: fix snprintf warnings
+      Fix compile errors in qdevice on FreeBSD
+      qdevice: mv free(str) after port validation
+      Fix various typos
+      Fix typo: recomended -> recommended
+      man: support SOURCE_DATE_EPOCH
+      configure: add --with-initconfigdir option
+      Use static case blocks to determine distro flavor
+      Use RuntimeDirectory instead of tmpfiles.d
+      coroparse: Do not convert empty uid, gid to 0
+      sam: Fix snprintf compiler warnings
+      quorumtool: Use full buffer size in snprintf
+      man: Add note about qdevice parallel cmds start
+      sync: Remove unneeded determine sync code
+      sync: Call sync_init of all services at once
+      corosync.conf: publicize nodelist.node.name
+      totemudp[u]: Drop truncated packets on receive
+      logging: Make blackbox configurable
+      logging: Close before and open blackbox after fork
+      init: Quote subshell result properly
+      blackbox: Quote subshell result properly
+      qdevice: quote certutils scripts properly
+      sam_test_agent: Remove unused assignment
+      qdevice: Fix NULL pointer dereference
+      quorumtool: Don't set our_flags without v_handle
+      qdevice: Nodelist is set into string not array
+      qdevice: Check if user_data can be dereferenced
+      qdevice: Add safer wrapper of strtoll
+      qdevice: Replace strtol by strtonum
+      qnetd: Replace strtol by strtonum
+      main: Set errno before calling of strtol
+      totemcrypto: Implement bad crypto header guess
+      cpg: Use list_del instead of qb_list_del
+      totemcrypto: Check length of the packet
+      totemsrp: Implement sanity checks of received msgs
+      totemsrp: Check join and leave msg length
+      totemudp: Check lenght of message to sent
+      qdevice msgio: Fix reading of msg longer than i32
+      logsys: Avoid redundant callsite section checking
+      man: corosync-qdevice: fix formatting vs. punctuation
+      man: corosync-qdevice: some more stylistics
+      man: fix cpg_mcast_joined.3.in
+      libcpg: Fix issue with partial big packet assembly
+      totempg: Fix fragmentation segfault
+      totempg: use iovec[i].iov_len instead of copy_len
+      totempg: Fix corrupted messages
+      cpg: Handle fragmented message sending interrupt
+      corosync.aug: Add missing options
+      systemd: Delete unnecessary soft_margin
+
+    Added:
+        corosync-2.4.4.tar.gz
+        0010-qdevice-net-instance.c-optarg-should-be-str.patch
+    Deleted:
+        0007-sync-Call-sync_init-of-all-services-at-once.patch
+        0008-wd-fix-snprintf-warnings.patch
+        0009-add-config-for-corosync-qnetd.patch
+        0010-qdevice-mv-free-str-after-port-validation.patch
+        0011-libcpg-Fix-issue-with-partial-big-packet-assembly.patch
+        0012-totemudp-u-Drop-truncated-packets-on-receive.patch
+        0013-logging-Make-blackbox-configurable.patch
+        0014-logging-Close-before-and-open-blackbox-after-fork.patch
+        0015-coverity-fixes.patch
+        0018-bsc#1089346-corosync-Integer-overflow-in-totemcrypto.patch
+        corosync-2.4.3.tar.gz
+    Renamed:
+        0009-add-config-for-corosync-qnetd.patch -> 
0007-add-config-for-corosync-qnetd.patch
+        0016-bsc#1083561-upgrade-from-1-x-y.patch -> 
0008-bsc#1083561-upgrade-from-1-x-y.patch
+        0017-bsc#1088619-add-version.patch -> 
0009-bsc#1088619-add-version.patch
+
+-------------------------------------------------------------------

Old:
----
  0007-sync-Call-sync_init-of-all-services-at-once.patch
  0008-wd-fix-snprintf-warnings.patch
  0009-add-config-for-corosync-qnetd.patch
  0010-qdevice-mv-free-str-after-port-validation.patch
  0011-libcpg-Fix-issue-with-partial-big-packet-assembly.patch
  0012-totemudp-u-Drop-truncated-packets-on-receive.patch
  0013-logging-Make-blackbox-configurable.patch
  0014-logging-Close-before-and-open-blackbox-after-fork.patch
  0015-coverity-fixes.patch
  0016-bsc#1083561-upgrade-from-1-x-y.patch
  0017-bsc#1088619-add-version.patch
  0018-bsc#1089346-corosync-Integer-overflow-in-totemcrypto.patch
  corosync-2.4.3.tar.gz

New:
----
  0007-add-config-for-corosync-qnetd.patch
  0008-bsc#1083561-upgrade-from-1-x-y.patch
  0009-bsc#1088619-add-version.patch
  0010-qdevice-net-instance.c-optarg-should-be-str.patch
  corosync-2.4.4.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ corosync.spec ++++++
--- /var/tmp/diff_new_pack.HQfAaw/_old  2018-04-22 14:34:43.315645251 +0200
+++ /var/tmp/diff_new_pack.HQfAaw/_new  2018-04-22 14:34:43.315645251 +0200
@@ -50,7 +50,7 @@
 Summary:        The Corosync Cluster Engine and Application Programming 
Interfaces
 License:        BSD-3-Clause
 Group:          Productivity/Clustering/HA
-Version:        2.4.3
+Version:        2.4.4
 Release:        0
 Url:            http://corosync.github.io/corosync/
 Source0:        %{name}-%{version}.tar.gz
@@ -68,18 +68,10 @@
 Patch11:        0004-mark-corosync-as-a-static-service.patch
 Patch12:        0005-do-not-convert-empty-uid-gid-to-0.patch
 Patch13:        0006-Fix-compile-warnings-with-GCC-7.2.1.patch
-Patch14:        0007-sync-Call-sync_init-of-all-services-at-once.patch
-Patch15:        0008-wd-fix-snprintf-warnings.patch
-Patch16:        0009-add-config-for-corosync-qnetd.patch
-Patch17:        0010-qdevice-mv-free-str-after-port-validation.patch
-Patch18:        0011-libcpg-Fix-issue-with-partial-big-packet-assembly.patch
-Patch19:        0012-totemudp-u-Drop-truncated-packets-on-receive.patch
-Patch20:        0013-logging-Make-blackbox-configurable.patch
-Patch21:        0014-logging-Close-before-and-open-blackbox-after-fork.patch
-Patch22:        0015-coverity-fixes.patch
-Patch23:        0016-bsc#1083561-upgrade-from-1-x-y.patch
-Patch24:        0017-bsc#1088619-add-version.patch
-Patch25:        0018-bsc#1089346-corosync-Integer-overflow-in-totemcrypto.patch
+Patch14:        0007-add-config-for-corosync-qnetd.patch
+Patch15:        0008-bsc#1083561-upgrade-from-1-x-y.patch
+Patch16:        0009-bsc#1088619-add-version.patch
+Patch17:        0010-qdevice-net-instance.c-optarg-should-be-str.patch
 
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 # openais is indeed gone and should be uninstalled. Yes, we do not
@@ -162,14 +154,6 @@
 %patch15 -p1
 %patch16 -p1
 %patch17 -p1
-%patch18 -p1
-%patch19 -p1
-%patch20 -p1
-%patch21 -p1
-%patch22 -p1
-%patch23 -p1
-%patch24 -p1
-%patch25 -p1
 
 %build
 %if %{with runautogen}
@@ -272,8 +256,6 @@
 %if %{with systemd}
 sed -i -e 's/^#User=/User=/' \
    %{buildroot}%{_unitdir}/corosync-qnetd.service
-sed -i -e 's/root/coroqnetd/g' \
-   %{buildroot}%{_tmpfilesdir}/corosync-qnetd.conf
 %else
 sed -i -e 's/^COROSYNC_QNETD_RUNAS=""$/COROSYNC_QNETD_RUNAS="coroqnetd"/' \
    %{buildroot}%{_sysconfdir}/sysconfig/corosync-qnetd
@@ -671,7 +653,6 @@
 exit 0
 
 %post -n corosync-qnetd
-%tmpfiles_create /usr/lib/tmpfiles.d/corosync-qnetd.conf
 %if %{sles_version} > 0
 ln -s /run/corosync-qnetd /var/run/
 %endif
@@ -706,7 +687,6 @@
 %{_sbindir}/rccorosync-qnetd
 %dir %{_datadir}/corosync
 %{_datadir}/corosync/corosync-qnetd
-%{_tmpfilesdir}/corosync-qnetd.conf
 %endif
 %{_mandir}/man8/corosync-qnetd-tool.8*
 %{_mandir}/man8/corosync-qnetd-certutil.8*

++++++ 0002-fix-ifdown-udp.patch ++++++
--- /var/tmp/diff_new_pack.HQfAaw/_old  2018-04-22 14:34:43.339644383 +0200
+++ /var/tmp/diff_new_pack.HQfAaw/_new  2018-04-22 14:34:43.339644383 +0200
@@ -1,8 +1,17 @@
+From ec2dfbec877fee166b31493e2dba41a850380608 Mon Sep 17 00:00:00 2001
+From: Bin Liu <b...@suse.com>
+Date: Tue, 17 Apr 2018 18:04:52 +0800
+Subject: [PATCH] totemudp: Add local loop support for unicast msgs
+
+---
+ exec/totemudp.c | 218 ++++++++++++++++++++++++++++++++------------------------
+ 1 file changed, 126 insertions(+), 92 deletions(-)
+
 diff --git a/exec/totemudp.c b/exec/totemudp.c
-index 31d05704..47830e4b 100644
+index 4b644ae..ea18897 100644
 --- a/exec/totemudp.c
 +++ b/exec/totemudp.c
-@@ -207,8 +207,6 @@ static int totemudp_build_sockets (
+@@ -205,8 +205,6 @@ static int totemudp_build_sockets (
        struct totemudp_socket *sockets,
        struct totem_ip_address *bound_to);
  
@@ -11,15 +20,15 @@
  static void totemudp_instance_initialize (struct totemudp_instance *instance)
  {
        memset (instance, 0, sizeof (struct totemudp_instance));
-@@ -269,6 +267,7 @@ static inline void ucast_sendmsg (
+@@ -267,6 +265,7 @@ static inline void ucast_sendmsg (
        struct sockaddr_storage sockaddr;
        struct iovec iovec;
        int addrlen;
 +      int send_sock;
  
-       /*
-        * Encrypt and digest the message
-@@ -313,11 +312,19 @@ static inline void ucast_sendmsg (
+       if (msg_len + crypto_get_current_sec_header_size(instance->crypto_inst) 
> sizeof(buf_out)) {
+               log_printf(LOGSYS_LEVEL_CRIT, "UDP message for ucast is too 
big. Ignoring message");
+@@ -317,11 +316,19 @@ static inline void ucast_sendmsg (
  #endif
  
  
@@ -30,7 +39,7 @@
 +              msg_ucast.msg_name = NULL;
 +              msg_ucast.msg_namelen = 0;
 +      }
-+
++        
        /*
         * Transmit unicast message
         * An error here is recovered by totemsrp
@@ -40,7 +49,7 @@
                MSG_NOSIGNAL);
        if (res < 0) {
                LOGSYS_PERROR (errno, instance->totemudp_log_level_debug,
-@@ -380,18 +387,20 @@ static inline void mcast_sendmsg (
+@@ -390,18 +397,20 @@ static inline void mcast_sendmsg (
        msg_mcast.msg_accrightslen = 0;
  #endif
  
@@ -73,7 +82,7 @@
        }
  
        /*
-@@ -556,7 +565,6 @@ static void timer_function_netif_check_timeout (
+@@ -580,7 +589,6 @@ static void timer_function_netif_check_timeout (
        struct totemudp_instance *instance = (struct totemudp_instance *)data;
        int interface_up;
        int interface_num;
@@ -81,7 +90,7 @@
  
        /*
         * Build sockets for every interface
-@@ -593,28 +601,31 @@ static void timer_function_netif_check_timeout (
+@@ -617,28 +625,31 @@ static void timer_function_netif_check_timeout (
                qb_loop_poll_del (instance->totemudp_poll_handle,
                        instance->totemudp_sockets.mcast_recv);
                close (instance->totemudp_sockets.mcast_recv);
@@ -120,7 +129,7 @@
  
                /*
                 * Add a timer to retry building interfaces and request 
memb_gather_enter
-@@ -630,34 +641,29 @@ static void timer_function_netif_check_timeout (
+@@ -654,34 +665,29 @@ static void timer_function_netif_check_timeout (
                 * Interface is up
                 */
                instance->netif_bind_state = BIND_STATE_REGULAR;
@@ -168,7 +177,7 @@
  
        totemip_copy (&instance->my_id, &instance->totem_interface->boundto);
  
-@@ -708,6 +714,66 @@ static void totemudp_traffic_control_set(struct 
totemudp_instance *instance, int
+@@ -732,6 +738,66 @@ static void totemudp_traffic_control_set(struct 
totemudp_instance *instance, int
  #endif
  }
  
@@ -235,21 +244,18 @@
  static int totemudp_build_sockets_ip (
        struct totemudp_instance *instance,
        struct totem_ip_address *mcast_address,
-@@ -730,7 +796,8 @@ static int totemudp_build_sockets_ip (
+@@ -755,7 +821,6 @@ static int totemudp_build_sockets_ip (
        int res;
        int flag;
        uint8_t sflag;
 -      int i;
-+
-+
  
        /*
         * Create multicast recv socket
-@@ -760,24 +827,6 @@ static int totemudp_build_sockets_ip (
-               return (-1);
+@@ -786,27 +851,6 @@ static int totemudp_build_sockets_ip (
        }
  
--      /*
+       /*
 -       * Create local multicast loop socket
 -       */
 -      if (socketpair(AF_UNIX, SOCK_DGRAM, 0, sockets->local_mcast_loop) == 
-1) {
@@ -267,10 +273,14 @@
 -                      return (-1);
 -              }
 -      }
- 
- 
- 
-@@ -875,18 +924,6 @@ static int totemudp_build_sockets_ip (
+-
+-
+-
+-      /*
+        * Setup mcast send socket
+        */
+       sockets->mcast_send = socket (bindnet_address->family, SOCK_DGRAM, 0);
+@@ -930,18 +974,6 @@ static int totemudp_build_sockets_ip (
                        "Unable to set SO_SNDBUF size on UDP mcast socket");
                return (-1);
        }
@@ -289,7 +299,7 @@
  
        res = getsockopt (sockets->mcast_recv, SOL_SOCKET, SO_RCVBUF, 
&recvbuf_size, &optlen);
        if (res == 0) {
-@@ -900,17 +937,6 @@ static int totemudp_build_sockets_ip (
+@@ -955,19 +987,6 @@ static int totemudp_build_sockets_ip (
                        "Transmit multicast socket send buffer size (%d 
bytes).", sendbuf_size);
        }
  
@@ -304,10 +314,12 @@
 -              log_printf (instance->totemudp_log_level_debug,
 -                      "Local transmit multicast loop socket send buffer size 
(%d bytes).", sendbuf_size);
 -      }
- 
- 
+-
+-
        /*
-@@ -1178,8 +1204,19 @@ int totemudp_initialize (
+        * Join group membership on socket
+        */
+@@ -1256,8 +1275,19 @@ int totemudp_initialize (
  
        instance->totemudp_target_set_completed = target_set_completed;
  
@@ -329,7 +341,7 @@
  
        /*
         * RRP layer isn't ready to receive message because it hasn't
-@@ -1242,10 +1279,14 @@ int totemudp_recv_flush (void *udp_context)
+@@ -1320,10 +1350,14 @@ int totemudp_recv_flush (void *udp_context)
        for (i = 0; i < 2; i++) {
                sock = -1;
                if (i == 0) {
@@ -337,7 +349,7 @@
 +                      if (instance->netif_bind_state == BIND_STATE_REGULAR) {
 +                              sock = instance->totemudp_sockets.mcast_recv;
 +                      } else {
-+                              continue ;
++                              continue;
 +                      }
                }
                if (i == 1) {
@@ -347,5 +359,5 @@
                assert(sock != -1);
  
 -- 
-2.12.3
+2.13.6
 

++++++ 0004-mark-corosync-as-a-static-service.patch ++++++
--- /var/tmp/diff_new_pack.HQfAaw/_old  2018-04-22 14:34:43.351643948 +0200
+++ /var/tmp/diff_new_pack.HQfAaw/_new  2018-04-22 14:34:43.355643804 +0200
@@ -1,8 +1,22 @@
---- corosync-2.4.2.orig/init/corosync.service.in       2017-08-29 
15:47:18.131052520 +0800
-+++ corosync-2.4.2/init/corosync.service.in    2017-08-29 15:46:24.949842298 
+0800
-@@ -23,4 +23,4 @@
- #ExecStartPre=/sbin/modprobe softdog soft_margin=60
+From f1c6610de162a1bcf4bedab28398ab3f0ac6bb9d Mon Sep 17 00:00:00 2001
+From: Bin Liu <b...@suse.com>
+Date: Tue, 17 Apr 2018 17:00:28 +0800
+Subject: [PATCH] mark corosync as a static service
+
+---
+ init/corosync.service.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/init/corosync.service.in b/init/corosync.service.in
+index 7733a98..e6c1805 100644
+--- a/init/corosync.service.in
++++ b/init/corosync.service.in
+@@ -23,4 +23,4 @@ Type=forking
+ #ExecStartPre=/sbin/modprobe softdog
  
  [Install]
 -WantedBy=multi-user.target
 +#WantedBy=multi-user.target
+-- 
+2.13.6
+

++++++ 0005-do-not-convert-empty-uid-gid-to-0.patch ++++++
--- /var/tmp/diff_new_pack.HQfAaw/_old  2018-04-22 14:34:43.367643370 +0200
+++ /var/tmp/diff_new_pack.HQfAaw/_new  2018-04-22 14:34:43.371643225 +0200
@@ -1,5 +1,14 @@
+From 31d931be66ef9ebf0aeb8e1dffa33e3280bfe732 Mon Sep 17 00:00:00 2001
+From: Bin Liu <b...@suse.com>
+Date: Tue, 17 Apr 2018 17:06:20 +0800
+Subject: [PATCH] do not convert empty uid gid to 0
+
+---
+ exec/coroparse.c | 12 ++++++++++++
+ 1 file changed, 12 insertions(+)
+
 diff --git a/exec/coroparse.c b/exec/coroparse.c
-index 374ed7dd..ac654a11 100644
+index 96bb83a..da82d54 100644
 --- a/exec/coroparse.c
 +++ b/exec/coroparse.c
 @@ -139,6 +139,12 @@ static int uid_determine (const char *req_user)
@@ -7,26 +16,26 @@
        char *ep;
  
 +      if(*req_user == '\0') {
-+              sprintf (error_string_response,
-+                     "The user can not be empty, please read the 
documentation.");
-+              return (-1);
++              sprintf (error_string_response,
++                      "The user can not be empty, please read the 
documentation.");
++              return (-1);
 +      }
 +
        id = strtol(req_user, &ep, 10);
-       if (*ep == '\0' && id >= 0 && id <= UINT_MAX) {
+       if (*req_user != '\0' && *ep == '\0' && id >= 0 && id <= UINT_MAX) {
                return (id);
 @@ -193,6 +199,12 @@ static int gid_determine (const char *req_group)
        long int id;
        char *ep;
  
 +      if(*req_group == '\0') {
-+              sprintf (error_string_response,
-+                      "The group can not be empty, please read the 
documentation.");
-+              return (-1);
++              sprintf (error_string_response,
++                      "The group can not be empty, please read the 
documentation.");
++              return (-1);
 +      }
 +
        id = strtol(req_group, &ep, 10);
-       if (*ep == '\0' && id >= 0 && id <= UINT_MAX) {
+       if (*req_group != '\0' && *ep == '\0' && id >= 0 && id <= UINT_MAX) {
                return (id);
 -- 
 2.13.6

++++++ 0006-Fix-compile-warnings-with-GCC-7.2.1.patch ++++++
--- /var/tmp/diff_new_pack.HQfAaw/_old  2018-04-22 14:34:43.379642935 +0200
+++ /var/tmp/diff_new_pack.HQfAaw/_new  2018-04-22 14:34:43.383642791 +0200
@@ -1,7 +1,4 @@
-1. sam: Fix snprintf compiler warnings
-2. cpg_test_agent: Fix snprintf compiler warnings
-3. quorumtool: Use full buffer size in snprintf
-4. readdir_r is deprecated in glibc 2.24 in favor of readdir
+//cpg_test_agent: Fix snprintf compiler warnings
 ---
  cts/agents/cpg_test_agent.c |  8 ++++----
  exec/coroparse.c            | 18 +++---------------
@@ -35,138 +32,6 @@
                        list_add_tail (&log_pt->list, &config_chg_log_head);
                        qb_log (LOG_INFO, "cpg event %s", log_pt->log);
                }
-diff --git a/exec/coroparse.c b/exec/coroparse.c
-index 2777a632..96bb83a5 100644
---- a/exec/coroparse.c
-+++ b/exec/coroparse.c
-@@ -1241,11 +1241,8 @@ static int read_uidgid_files_into_icmap(
-       const char *dirname;
-       DIR *dp;
-       struct dirent *dirent;
--      struct dirent *entry;
-       char filename[PATH_MAX + FILENAME_MAX + 1];
-       int res = 0;
--      size_t len;
--      int return_code;
-       struct stat stat_buf;
-       enum main_cp_cb_data_state state = MAIN_CP_CB_DATA_STATE_NORMAL;
-       char key_name[ICMAP_KEYNAME_MAXLEN];
-@@ -1256,17 +1253,9 @@ static int read_uidgid_files_into_icmap(
-       if (dp == NULL)
-               return 0;
- 
--      len = offsetof(struct dirent, d_name) + FILENAME_MAX + 1;
--
--      entry = malloc(len);
--      if (entry == NULL) {
--              res = 0;
--              goto error_exit;
--      }
--
--      for (return_code = readdir_r(dp, entry, &dirent);
--              dirent != NULL && return_code == 0;
--              return_code = readdir_r(dp, entry, &dirent)) {
-+      for (dirent = readdir(dp);
-+              dirent != NULL;
-+              dirent = readdir(dp)) {
- 
-               snprintf(filename, sizeof (filename), "%s/%s", dirname, 
dirent->d_name);
-               res = stat (filename, &stat_buf);
-@@ -1288,7 +1277,6 @@ static int read_uidgid_files_into_icmap(
-       }
- 
- error_exit:
--      free (entry);
-       closedir(dp);
- 
-       return res;
-diff --git a/lib/sam.c b/lib/sam.c
-index 33aa3944..527b99cb 100644
---- a/lib/sam.c
-+++ b/lib/sam.c
-@@ -145,6 +145,7 @@ static cs_error_t sam_cmap_update_key (enum sam_cmap_key_t 
key, const char *valu
-       cs_error_t err;
-       const char *svalue;
-       uint64_t hc_period, last_hc;
-+
-       const char *ssvalue[] = { [SAM_RECOVERY_POLICY_QUIT] = "quit", 
[SAM_RECOVERY_POLICY_RESTART] = "restart" };
-       char key_name[CMAP_KEYNAME_MAXLEN];
- 
-@@ -152,8 +153,13 @@ static cs_error_t sam_cmap_update_key (enum 
sam_cmap_key_t key, const char *valu
-       case SAM_CMAP_KEY_RECOVERY:
-               svalue = ssvalue[SAM_RP_MASK 
(sam_internal_data.recovery_policy)];
- 
--              snprintf(key_name, CMAP_KEYNAME_MAXLEN, "%s%s", 
sam_internal_data.cmap_pid_path,
--                              "recovery");
-+              if (snprintf(key_name, CMAP_KEYNAME_MAXLEN, "%s%s", 
sam_internal_data.cmap_pid_path,
-+                  "recovery") >= CMAP_KEYNAME_MAXLEN) {
-+
-+                      err = CS_ERR_NAME_TOO_LONG;
-+                      goto exit_error;
-+              }
-+
-               if ((err = cmap_set_string(sam_internal_data.cmap_handle, 
key_name, svalue)) != CS_OK) {
-                       goto exit_error;
-               }
-@@ -161,8 +167,13 @@ static cs_error_t sam_cmap_update_key (enum 
sam_cmap_key_t key, const char *valu
-       case SAM_CMAP_KEY_HC_PERIOD:
-               hc_period = sam_internal_data.time_interval;
- 
--              snprintf(key_name, CMAP_KEYNAME_MAXLEN, "%s%s", 
sam_internal_data.cmap_pid_path,
--                              "poll_period");
-+              if (snprintf(key_name, CMAP_KEYNAME_MAXLEN, "%s%s", 
sam_internal_data.cmap_pid_path,
-+                  "poll_period") >= CMAP_KEYNAME_MAXLEN) {
-+
-+                      err = CS_ERR_NAME_TOO_LONG;
-+                      goto exit_error;
-+              }
-+
-               if ((err = cmap_set_uint64(sam_internal_data.cmap_handle, 
key_name, hc_period)) != CS_OK) {
-                       goto exit_error;
-               }
-@@ -170,16 +181,25 @@ static cs_error_t sam_cmap_update_key (enum 
sam_cmap_key_t key, const char *valu
-       case SAM_CMAP_KEY_LAST_HC:
-               last_hc = cs_timestamp_get();
- 
--              snprintf(key_name, CMAP_KEYNAME_MAXLEN, "%s%s", 
sam_internal_data.cmap_pid_path,
--                              "last_updated");
-+              if (snprintf(key_name, CMAP_KEYNAME_MAXLEN, "%s%s", 
sam_internal_data.cmap_pid_path,
-+                  "last_updated") >= CMAP_KEYNAME_MAXLEN) {
-+
-+                      err = CS_ERR_NAME_TOO_LONG;
-+                      goto exit_error;
-+              }
-               if ((err = cmap_set_uint64(sam_internal_data.cmap_handle, 
key_name, last_hc)) != CS_OK) {
-                       goto exit_error;
-               }
-               break;
-       case SAM_CMAP_KEY_STATE:
-               svalue = value;
--              snprintf(key_name, CMAP_KEYNAME_MAXLEN, "%s%s", 
sam_internal_data.cmap_pid_path,
--                              "state");
-+              if (snprintf(key_name, CMAP_KEYNAME_MAXLEN, "%s%s", 
sam_internal_data.cmap_pid_path,
-+                  "state") >= CMAP_KEYNAME_MAXLEN) {
-+
-+                      err = CS_ERR_NAME_TOO_LONG;
-+                      goto exit_error;
-+              }
-+
-               if ((err = cmap_set_string(sam_internal_data.cmap_handle, 
key_name, svalue)) != CS_OK) {
-                       goto exit_error;
-               }
-diff --git a/tools/corosync-quorumtool.c b/tools/corosync-quorumtool.c
-index 52c141ce..19696659 100644
---- a/tools/corosync-quorumtool.c
-+++ b/tools/corosync-quorumtool.c
-@@ -519,7 +519,7 @@ static void display_nodes_data(nodeid_format_t 
nodeid_format, name_format_t name
-                               if (info[i].flags & 
VOTEQUORUM_INFO_QDEVICE_REGISTERED) {
-                                       char buf[10];
- 
--                                      snprintf(buf, sizeof(buf) - 1,
-+                                      snprintf(buf, sizeof(buf),
-                                                "%s,%s,%s",
-                                                info[i].flags & 
VOTEQUORUM_INFO_QDEVICE_ALIVE?"A":"NA",
-                                                info[i].flags & 
VOTEQUORUM_INFO_QDEVICE_CAST_VOTE?"V":"NV",
 -- 
 2.13.6
 

++++++ 0009-add-config-for-corosync-qnetd.patch -> 
0007-add-config-for-corosync-qnetd.patch ++++++

++++++ 0016-bsc#1083561-upgrade-from-1-x-y.patch -> 
0008-bsc#1083561-upgrade-from-1-x-y.patch ++++++

++++++ 0017-bsc#1088619-add-version.patch -> 0009-bsc#1088619-add-version.patch 
++++++
--- /work/SRC/openSUSE:Factory/corosync/0017-bsc#1088619-add-version.patch      
2018-04-17 11:13:22.458067939 +0200
+++ /work/SRC/openSUSE:Factory/.corosync.new/0009-bsc#1088619-add-version.patch 
2018-04-22 14:34:42.379679124 +0200
@@ -1,4 +1,4 @@
 --- /dev/null 2018-04-10 08:30:37.121221591 +0800
 +++ corosync-2.4.3/.tarball-version 2018-04-10 18:30:37.907779088 +0800
 @@ -0,0 +1 @@
-+2.4.3
++2.4.4

++++++ 0010-qdevice-net-instance.c-optarg-should-be-str.patch ++++++
>From fab3ef5e63e1ad61d03b1230e8f900bf1279cc81 Mon Sep 17 00:00:00 2001
From: Bin Liu <b...@suse.com>
Date: Thu, 19 Apr 2018 16:52:27 +0800
Subject: [PATCH] qdevice-net-instance.c: optarg should be str

---
 qdevices/qdevice-net-instance.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/qdevices/qdevice-net-instance.c b/qdevices/qdevice-net-instance.c
index 87cf3ee0..a3231cd5 100644
--- a/qdevices/qdevice-net-instance.c
+++ b/qdevices/qdevice-net-instance.c
@@ -273,7 +273,7 @@ qdevice_net_instance_init_from_cmap(struct qdevice_instance 
*instance)
        host_addr = str;
 
        if (cmap_get_string(cmap_handle, "quorum.device.net.port", &str) == 
CS_OK) {
-               if (utils_strtonum(optarg, 1, UINT16_MAX, &lli) == -1) {
+               if (utils_strtonum(str, 1, UINT16_MAX, &lli) == -1) {
                        qdevice_log(LOG_ERR, "quorum.device.net.port must be in 
range 1-%u", UINT16_MAX);
                        free(str);
                        goto error_free_host_addr;
-- 
2.13.6

++++++ corosync-2.4.3.tar.gz -> corosync-2.4.4.tar.gz ++++++
++++ 3847 lines of diff (skipped)


Reply via email to