Hello community, here is the log from the commit of package libsmpp34 for openSUSE:Factory checked in at 2019-08-22 10:50:12 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/libsmpp34 (Old) and /work/SRC/openSUSE:Factory/.libsmpp34.new.22127 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "libsmpp34" Thu Aug 22 10:50:12 2019 rev:4 rq:723418 version:1.14.0 Changes: -------- --- /work/SRC/openSUSE:Factory/libsmpp34/libsmpp34.changes 2019-02-01 11:44:55.832584215 +0100 +++ /work/SRC/openSUSE:Factory/.libsmpp34.new.22127/libsmpp34.changes 2019-08-22 10:50:20.485716239 +0200 @@ -1,0 +2,6 @@ +Thu Aug 15 05:01:44 UTC 2019 - Jan Engelhardt <[email protected]> + +- Update to new upstream release 1.14.0 + * Allow application to override default heap allocator + +------------------------------------------------------------------- Old: ---- libsmpp34-1.13.0.tar.xz New: ---- libsmpp34-1.14.0.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ libsmpp34.spec ++++++ --- /var/tmp/diff_new_pack.1faivH/_old 2019-08-22 10:50:22.041716031 +0200 +++ /var/tmp/diff_new_pack.1faivH/_new 2019-08-22 10:50:22.041716031 +0200 @@ -19,7 +19,7 @@ %define sover 1 Name: libsmpp34 -Version: 1.13.0 +Version: 1.14.0 Release: 0 Summary: PDU SMPP packaging and unpackaging tool License: GPL-2.0-or-later AND LGPL-2.1-or-later @@ -52,7 +52,7 @@ Group: Development/Libraries/C and C++ Requires: libsmpp34-%sover = %version # Wrong package name -Obsoletes: libsmpp34-0-devel <= %version-%release +Obsoletes: libsmpp34-0-devel < %version-%release Provides: libsmpp34-0-devel = %version-%release %description devel ++++++ _service ++++++ --- /var/tmp/diff_new_pack.1faivH/_old 2019-08-22 10:50:22.061716028 +0200 +++ /var/tmp/diff_new_pack.1faivH/_new 2019-08-22 10:50:22.061716028 +0200 @@ -2,8 +2,8 @@ <service name="tar_scm" mode="disabled"> <param name="scm">git</param> <param name="url">git://git.osmocom.org/libsmpp34</param> - <param name="revision">1.13.0</param> - <param name="versionformat">1.13.0</param> + <param name="revision">1.14.0</param> + <param name="versionformat">1.14.0</param> </service> <service name="recompress" mode="disabled"> <param name="file">*.tar</param> ++++++ libsmpp34-1.13.0.tar.xz -> libsmpp34-1.14.0.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libsmpp34-1.13.0/configure.ac new/libsmpp34-1.14.0/configure.ac --- old/libsmpp34-1.13.0/configure.ac 2018-05-03 18:04:11.000000000 +0200 +++ new/libsmpp34-1.14.0/configure.ac 2019-08-07 14:48:07.000000000 +0200 @@ -8,6 +8,9 @@ AM_INIT_AUTOMAKE([foreign]) AM_CONFIG_HEADER([aux_config/config.h]) +dnl kernel style compile messages +m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) + dnl include release helper RELMAKE='-include osmo-release.mk' AC_SUBST([RELMAKE]) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libsmpp34-1.13.0/contrib/jenkins.sh new/libsmpp34-1.14.0/contrib/jenkins.sh --- old/libsmpp34-1.13.0/contrib/jenkins.sh 2018-05-03 18:04:11.000000000 +0200 +++ new/libsmpp34-1.14.0/contrib/jenkins.sh 2019-08-07 14:48:07.000000000 +0200 @@ -10,5 +10,6 @@ $MAKE $MAKE $PARALLEL_MAKE $MAKE distcheck || cat-testlogs.sh +$MAKE maintainer-clean osmo-clean-workspace.sh diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libsmpp34-1.13.0/debian/changelog new/libsmpp34-1.14.0/debian/changelog --- old/libsmpp34-1.13.0/debian/changelog 2018-05-03 18:04:11.000000000 +0200 +++ new/libsmpp34-1.14.0/debian/changelog 2019-08-07 14:48:07.000000000 +0200 @@ -1,3 +1,26 @@ +libsmpp34 (1.14.0) unstable; urgency=medium + + [ Pau Espin Pedrol ] + * debian/rules: Don't overwrite .tarball-version + + [ Neels Hofmeyr ] + * esme.c: mark switch statement fall-thru for coverity + + [ Stefan Sperling ] + * fix use of partly initialized struct in tcp test + + [ Vadim Yanitskiy ] + * configure.ac: enable kernel style compile messages + + [ Harald Welte ] + * Allow application to override default heap allocator + * bind_receiver_test: Fix "unused value" of writing addr_ton twice + + [ Oliver Smith ] + * contrib/jenkins.sh: run "make maintainer-clean" + + -- Pau Espin Pedrol <[email protected]> Wed, 07 Aug 2019 14:48:06 +0200 + libsmpp34 (1.13.0) unstable; urgency=medium [ Holger Hans Peter Freyther ] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libsmpp34-1.13.0/debian/rules new/libsmpp34-1.14.0/debian/rules --- old/libsmpp34-1.13.0/debian/rules 2018-05-03 18:04:11.000000000 +0200 +++ new/libsmpp34-1.14.0/debian/rules 2019-08-07 14:48:07.000000000 +0200 @@ -14,10 +14,6 @@ override_dh_strip: dh_strip --dbg-package=libsmpp34-dbg -override_dh_autoreconf: - echo $(VERSION) > .tarball-version - dh_autoreconf - # Print test results in case of a failure override_dh_auto_test: dh_auto_test || (find . -name testsuite.log -exec cat {} \; ; false) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libsmpp34-1.13.0/src/Makefile.am new/libsmpp34-1.14.0/src/Makefile.am --- old/libsmpp34-1.13.0/src/Makefile.am 2018-05-03 18:04:11.000000000 +0200 +++ new/libsmpp34-1.14.0/src/Makefile.am 2019-08-07 14:48:07.000000000 +0200 @@ -1,6 +1,6 @@ # This is _NOT_ the library release version, it's an API version. # Please read Chapter 6 "Library interface versions" of the libtool documentation before making any modification -LIBVERSION=1:0:0 +LIBVERSION=2:0:1 # src/Makefile.am # lib_LTLIBRARIES = libsmpp34.la @@ -10,6 +10,7 @@ $(LIBRARY_SOURCE_DIR)/smpp34.h \ $(LIBRARY_SOURCE_DIR)/smpp34_dumpBuf.c \ $(LIBRARY_SOURCE_DIR)/smpp34_dumpPdu.c \ + $(LIBRARY_SOURCE_DIR)/smpp34_heap.c \ $(LIBRARY_SOURCE_DIR)/smpp34_pack.c \ $(LIBRARY_SOURCE_DIR)/smpp34_unpack.c \ $(LIBRARY_SOURCE_DIR)/smpp34_structs.c \ @@ -19,6 +20,7 @@ include_HEADERS = \ $(LIBRARY_SOURCE_DIR)/smpp34.h \ + $(LIBRARY_SOURCE_DIR)/smpp34_heap.h \ $(LIBRARY_SOURCE_DIR)/smpp34_structs.h \ $(LIBRARY_SOURCE_DIR)/smpp34_params.h diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libsmpp34-1.13.0/src/smpp34_heap.c new/libsmpp34-1.14.0/src/smpp34_heap.c --- old/libsmpp34-1.13.0/src/smpp34_heap.c 1970-01-01 01:00:00.000000000 +0100 +++ new/libsmpp34-1.14.0/src/smpp34_heap.c 2019-08-07 14:48:07.000000000 +0200 @@ -0,0 +1,77 @@ +/* + * Copyright (C) 2019 Harald Welte + * File : smpp34_heap.c + * Author: Harald Welte <[email protected]> + * + * This file is part of libsmpp34 (c-open-smpp3.4 library). + * + * The libsmpp34 library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2.1 of the + * License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY + * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public + * License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this library; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * + */ + +#include <stdio.h> +#include <stdlib.h> +#include <stdbool.h> + +#include "smpp34_heap.h" + +static void *smpp34_libc_malloc(size_t sz) +{ + return malloc(sz); +} + +static void *smpp34_libc_realloc(void *ptr, size_t sz) +{ + return realloc(ptr, sz); +} + +static void smpp34_libc_free(void *ptr) +{ + return free(ptr); +} + +static bool allocator_used = false; + +static struct smpp34_memory_functions smpp34_allocator = { + .malloc_fun = smpp34_libc_malloc, + .realloc_fun = smpp34_libc_realloc, + .free_fun = smpp34_libc_free, +}; + +void smpp34_set_memory_functions(const struct smpp34_memory_functions *mf) +{ + if (allocator_used) { + fprintf(stderr, "%s must be called before first use of smpp34_malloc\n", __func__); + return; + } + smpp34_allocator = *mf; +} + +void *smpp34_malloc(size_t sz) +{ + allocator_used = true; + return smpp34_allocator.malloc_fun(sz); +} + +void *smpp34_realloc(void *ptr, size_t sz) +{ + allocator_used = true; + return smpp34_allocator.realloc_fun(ptr, sz); +} + +void smpp34_free(void *ptr) +{ + smpp34_allocator.free_fun(ptr); +} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libsmpp34-1.13.0/src/smpp34_heap.h new/libsmpp34-1.14.0/src/smpp34_heap.h --- old/libsmpp34-1.13.0/src/smpp34_heap.h 1970-01-01 01:00:00.000000000 +0100 +++ new/libsmpp34-1.14.0/src/smpp34_heap.h 2019-08-07 14:48:07.000000000 +0200 @@ -0,0 +1,15 @@ +#pragma once +#include <stddef.h> + +/* override the allocator with these methods; to be called BEFORE allocating anything */ +struct smpp34_memory_functions { + void * (*malloc_fun)(size_t sz); + void * (*realloc_fun)(void *ptr, size_t sz); + void (*free_fun)(void *ptr); +}; + +void smpp34_set_memory_functions(const struct smpp34_memory_functions *mf); + +void *smpp34_malloc(size_t sz); +void *smpp34_realloc(void *ptr, size_t sz); +void smpp34_free(void *ptr); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libsmpp34-1.13.0/src/smpp34_params.c new/libsmpp34-1.14.0/src/smpp34_params.c --- old/libsmpp34-1.13.0/src/smpp34_params.c 2018-05-03 18:04:11.000000000 +0200 +++ new/libsmpp34-1.14.0/src/smpp34_params.c 2019-08-07 14:48:07.000000000 +0200 @@ -27,15 +27,16 @@ #include "smpp34.h" #include "smpp34_structs.h" +#include "smpp34_heap.h" int build_udad( udad_t **dest, udad_t *source ) { /* Build new DAD-Chain ************************************************/ - udad_t *dummy = (udad_t*)malloc(sizeof( udad_t )); + udad_t *dummy = (udad_t*)smpp34_malloc(sizeof( udad_t )); if( dummy == NULL ){ - printf("Error in malloc()\n" ); + printf("Error in smpp34_malloc()\n" ); return( -1 ); }; memcpy(dummy, source, sizeof( udad_t )); @@ -54,7 +55,7 @@ /* Destroy DAD-Chain **************************************************/ while( sourceList != NULL ){ i = sourceList->next; - free((void*)sourceList); + smpp34_free((void*)sourceList); sourceList = i; }; @@ -68,9 +69,9 @@ { /* Build new DAD-Chain ************************************************/ - dad_t *dummy = (dad_t*)malloc(sizeof( dad_t )); + dad_t *dummy = (dad_t*)smpp34_malloc(sizeof( dad_t )); if( dummy == NULL ){ - printf("Error in malloc()\n" ); + printf("Error in smpp34_malloc()\n" ); return( -1 ); }; memcpy(dummy, source, sizeof( dad_t )); @@ -89,7 +90,7 @@ /* Destroy DAD-Chain **************************************************/ while( sourceList != NULL ){ i = sourceList->next; - free((void*)sourceList); + smpp34_free((void*)sourceList); sourceList = i; }; @@ -102,9 +103,9 @@ { /* Build new TLV-Chain ************************************************/ - tlv_t *dummy = (tlv_t*)malloc(sizeof( tlv_t )); + tlv_t *dummy = (tlv_t*)smpp34_malloc(sizeof( tlv_t )); if( dummy == NULL ){ - printf("Error in malloc()\n" ); + printf("Error in smpp34_malloc()\n" ); return( -1 ); }; memcpy(dummy, source, sizeof( tlv_t )); @@ -123,7 +124,7 @@ /* Destroy TLV-Chain **************************************************/ while( sourceList != NULL ){ i = sourceList->next; - free((void*)sourceList); + smpp34_free((void*)sourceList); sourceList = i; }; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libsmpp34-1.13.0/src/smpp34_unpack.c new/libsmpp34-1.14.0/src/smpp34_unpack.c --- old/libsmpp34-1.13.0/src/smpp34_unpack.c 2018-05-03 18:04:11.000000000 +0200 +++ new/libsmpp34-1.14.0/src/smpp34_unpack.c 2019-08-07 14:48:07.000000000 +0200 @@ -31,6 +31,7 @@ #include "smpp34.h" #include "smpp34_structs.h" #include "smpp34_params.h" +#include "smpp34_heap.h" /* GLOBALS ********************************************************************/ /* EXTERN *********************************************************************/ @@ -179,7 +180,7 @@ #define TLV( inst, tlv3, do_tlv ){\ tlv_t *aux_tlv = NULL;\ while( (aux - ini) < t1->command_length ){\ - aux_tlv = (tlv_t *) malloc(sizeof( tlv_t ));\ + aux_tlv = (tlv_t *) smpp34_malloc(sizeof( tlv_t ));\ memset(aux_tlv, 0, sizeof(tlv_t));\ do_tlv( aux_tlv );\ aux_tlv->next = inst tlv3;\ @@ -191,7 +192,7 @@ udad_t *aux_udad = NULL;\ int c = 0;\ while( c < t1->no_unsuccess ){\ - aux_udad = (udad_t *) malloc(sizeof( udad_t ));\ + aux_udad = (udad_t *) smpp34_malloc(sizeof( udad_t ));\ memset(aux_udad, 0, sizeof(udad_t));\ do_udad( aux_udad );\ aux_udad->next = inst udad3;\ @@ -204,7 +205,7 @@ dad_t *aux_dad = NULL;\ int c = 0;\ while( c < t1->number_of_dests ){\ - aux_dad = (dad_t *) malloc(sizeof( dad_t ));\ + aux_dad = (dad_t *) smpp34_malloc(sizeof( dad_t ));\ memset(aux_dad, 0, sizeof(dad_t));\ do_dad( aux_dad );\ aux_dad->next = inst dad3;\ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libsmpp34-1.13.0/test_apps/esme.c new/libsmpp34-1.14.0/test_apps/esme.c --- old/libsmpp34-1.13.0/test_apps/esme.c 2018-05-03 18:04:11.000000000 +0200 +++ new/libsmpp34-1.14.0/test_apps/esme.c 2019-08-07 14:48:07.000000000 +0200 @@ -56,6 +56,7 @@ break; default: printf("Error: unrecognized option\n"); + /* fall thru */ case 'h': printf("usage: %s %s\n", argv[0], HELP_FORMAT); return( -1 ); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libsmpp34-1.13.0/test_apps/tcp.c new/libsmpp34-1.14.0/test_apps/tcp.c --- old/libsmpp34-1.13.0/test_apps/tcp.c 2018-05-03 18:04:11.000000000 +0200 +++ new/libsmpp34-1.14.0/test_apps/tcp.c 2019-08-07 14:48:07.000000000 +0200 @@ -69,7 +69,7 @@ /* bind to a local addr */ if (strlen(local_src) != 0) { - struct sockaddr_in name; + memset(&name, 0, sizeof(name)); name.sin_family = AF_INET; name.sin_port = htons(local_port); name.sin_addr.s_addr = inet_addr(local_src); @@ -91,6 +91,7 @@ }; memcpy(&addr.s_addr, _host.h_addr_list[0], sizeof(struct in_addr)); + memset(&name, 0, sizeof(name)); name.sin_family = AF_INET; name.sin_port = htons( port ); name.sin_addr = addr; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/libsmpp34-1.13.0/test_pdu/bind_receiver_test.c new/libsmpp34-1.14.0/test_pdu/bind_receiver_test.c --- old/libsmpp34-1.13.0/test_pdu/bind_receiver_test.c 2018-05-03 18:04:11.000000000 +0200 +++ new/libsmpp34-1.14.0/test_pdu/bind_receiver_test.c 2019-08-07 14:48:07.000000000 +0200 @@ -53,7 +53,7 @@ snprintf((char*)b.system_id, sizeof(b.system_id), "%s", "system_id"); snprintf((char*)b.password, sizeof(b.password), "%s", "pass"); snprintf((char*)b.system_type, sizeof(b.system_type), "%s", "syste"); - b.addr_ton = 0x34; + b.interface_version = 0x34; b.addr_ton = 2; b.addr_npi = 1; snprintf((char*)b.address_range, sizeof(b.address_range), "%s", "address_range");
