Hello community,
here is the log from the commit of package iio-sensor-proxy for openSUSE:Factory checked in at 2017-02-09 11:17:52
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/iio-sensor-proxy (Old)
and /work/SRC/openSUSE:Factory/.iio-sensor-proxy.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "iio-sensor-proxy"
Changes:
--------
--- /work/SRC/openSUSE:Factory/iio-sensor-proxy/iio-sensor-proxy.changes 2016-12-26 21:45:45.428599276 +0100
+++ /work/SRC/openSUSE:Factory/.iio-sensor-proxy.new/iio-sensor-proxy.changes 2017-02-09 11:17:54.479618433 +0100
@@ -1,0 +2,15 @@
+Thu Feb 2 15:47:58 UTC 2017 - zaitor@opensuse.org
+
+- Update to version 2.1:
+ + This release fixes a security problem that will affect services
+ other than iio-sensor-proxy, that have a system D-Bus
+ interface.
+ + Make D-Bus policy rules only affect SensorProxy itself.
+ + Lockdown service through systemd.
+ + Fix startup problem on machines with a Compass device.
+- Do not use systemd macros for iio-sensor-proxy.service, they are
+ not designed for dbus systemd unit file.
+- Add iio-sensor-proxy-rpmlintrc, silence the unwarranted rpmlint
+ warnings now produced.
+
+-------------------------------------------------------------------
Old:
----
iio-sensor-proxy-2.0.tar.xz
New:
----
iio-sensor-proxy-2.1.tar.xz
iio-sensor-proxy-rpmlintrc
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ iio-sensor-proxy.spec ++++++
--- /var/tmp/diff_new_pack.vN6nXw/_old 2017-02-09 11:17:55.015542596 +0100
+++ /var/tmp/diff_new_pack.vN6nXw/_new 2017-02-09 11:17:55.019542030 +0100
@@ -1,7 +1,7 @@
#
# spec file for package iio-sensor-proxy
#
-# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -17,12 +17,13 @@
Name: iio-sensor-proxy
-Version: 2.0
+Version: 2.1
Release: 0
Summary: Proxy for IIO and input subsystems
License: GPL-3.0
Url: https://github.com/hadess/iio-sensor-proxy
-Source: https://github.com/hadess/iio-sensor-proxy/releases/download/%{version}/%{name}-%{version}.tar.xz
+Source0: https://github.com/hadess/iio-sensor-proxy/releases/download/%{version}/%{name}-%{version}.tar.xz
+Source99: iio-sensor-proxy-rpmlintrc
BuildRequires: gtk-doc
BuildRequires: pkgconfig
BuildRequires: pkgconfig(glib-2.0)
@@ -52,22 +53,12 @@
%install
%make_install
-install -d %{buildroot}%{_sbindir}
-ln -s %{_sbindir}/service %{buildroot}%{_sbindir}/rc%{name}
-
-%pre
-%service_add_pre iio-sensor-proxy.service
%post
%udev_hwdb_update
%udev_rules_update
-%service_add_post iio-sensor-proxy.service
-
-%preun
-%service_del_preun iio-sensor-proxy.service
%postun
-%service_del_postun iio-sensor-proxy.service
%udev_hwdb_update
%udev_rules_update
@@ -75,7 +66,6 @@
%defattr(-,root,root)
%{_bindir}/monitor-sensor
%{_sbindir}/iio-sensor-proxy
-%{_sbindir}/rc%{name}
%{_udevrulesdir}/*.rules
%{_unitdir}/iio-sensor-proxy.service
# Own dirs to avoid depending on dbus while building.
++++++ iio-sensor-proxy-2.0.tar.xz -> iio-sensor-proxy-2.1.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iio-sensor-proxy-2.0/NEWS new/iio-sensor-proxy-2.1/NEWS
--- old/iio-sensor-proxy-2.0/NEWS 2016-12-12 13:29:58.000000000 +0100
+++ new/iio-sensor-proxy-2.1/NEWS 2017-02-02 16:20:02.000000000 +0100
@@ -1,3 +1,14 @@
+2.1
+---
+
+This release fixes a security problem that will affect services
+other than iio-sensor-proxy, that have a system D-Bus interface.
+Upgrading to this version is highly recommended.
+
+- Make D-Bus policy rules only affect SensorProxy itself
+- Lockdown service through systemd
+- Fix startup problem on machines with a Compass device
+
2.0
---
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iio-sensor-proxy-2.0/README new/iio-sensor-proxy-2.1/README
--- old/iio-sensor-proxy-2.0/README 2016-12-10 16:52:07.000000000 +0100
+++ new/iio-sensor-proxy-2.1/README 2017-02-02 16:08:21.000000000 +0100
@@ -72,6 +72,20 @@
`ACCEL_MOUNT_MATRIX` udev property. See [60-sensor.hwdb](https://github.com/systemd/systemd/blob/master/hwdb/60-sensor.hwdb)
for details.
+Compass testing
+---------------
+
+Only the Geoclue daemon (as the geoclue user) is allowed to access the `net.hadess.SensorProxy.Compass`
+interface, the results of which it will propagate to clients along with positional information.
+
+If your device does not contain a compass, you can run tests with:
+- If your device does not contain a real compass:
+ - Add FAKE_COMPASS=1 to the environment of `iio-sensor-proxy.service` if your device does not contain a real one
+ - Run the daemon manually with `systemctl start iio-sensor-proxy.service`
+- Verify that iio-sensor-proxy is running with `systemctl` or `ps`
+- As root, get a shell as the `geoclue` user with `su -s /bin/bash geoclue`
+- Run, as the `geoclue` user, `monitor-sensor`
+
References
----------
@@ -82,22 +96,26 @@
Tested on
---------
+- Apple MacBook Air (4,2)
+- Apple MacBook Air (6,2)
+- Apple MacBook Pro (8.2)
+- Asus Transformer Book TP500LB
+- Asus Zenbook UX31A, UX305
+- Cube i9
+- Dell Inspiron 13 7000
+- Dell Venue 11 Pro (7140)
+- Dell Venue 8 Pro
+- HP Pavilion X360
+- HP Spectre x360 (Kaby Lake)
- Lenovo IdeaPad Yoga 13
-- Microsoft Surface Pro 2
-- Lenovo Yoga 2 Pro
+- Lenovo ThinkPad Twist
+- Lenovo X1 Carbon 2014 (rev2)
+- Lenovo X1 Tablet
- Lenovo Yoga 2 13" and 11"
+- Lenovo Yoga 2 Pro
+- Lenovo Yoga 460
- Lenovo Yoga 900
+- Microsoft Surface Pro 2
- Onda v975w
-- Dell Venue 8 Pro
-- Dell Venue 11 Pro (7140)
-- Lenovo ThinkPad Twist
-- MacBook Pro (8.2)
-- Lenovo X1 Carbon 2014 (rev2)
-- MacBook Air (6,2)
-- MacBook Air (4,2)
- Toshiba Portégé Z10t
- Toshiba Radius 11 L10WC10C
-- Dell Inspiron 13 7000
-- Cube i9
-- HP Pavilion X360
-- Asus Zenbook UX31A, UX305
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iio-sensor-proxy-2.0/README.md new/iio-sensor-proxy-2.1/README.md
--- old/iio-sensor-proxy-2.0/README.md 2016-12-10 16:52:07.000000000 +0100
+++ new/iio-sensor-proxy-2.1/README.md 2017-02-02 16:08:21.000000000 +0100
@@ -72,6 +72,20 @@
`ACCEL_MOUNT_MATRIX` udev property. See [60-sensor.hwdb](https://github.com/systemd/systemd/blob/master/hwdb/60-sensor.hwdb)
for details.
+Compass testing
+---------------
+
+Only the Geoclue daemon (as the geoclue user) is allowed to access the `net.hadess.SensorProxy.Compass`
+interface, the results of which it will propagate to clients along with positional information.
+
+If your device does not contain a compass, you can run tests with:
+- If your device does not contain a real compass:
+ - Add FAKE_COMPASS=1 to the environment of `iio-sensor-proxy.service` if your device does not contain a real one
+ - Run the daemon manually with `systemctl start iio-sensor-proxy.service`
+- Verify that iio-sensor-proxy is running with `systemctl` or `ps`
+- As root, get a shell as the `geoclue` user with `su -s /bin/bash geoclue`
+- Run, as the `geoclue` user, `monitor-sensor`
+
References
----------
@@ -82,22 +96,26 @@
Tested on
---------
+- Apple MacBook Air (4,2)
+- Apple MacBook Air (6,2)
+- Apple MacBook Pro (8.2)
+- Asus Transformer Book TP500LB
+- Asus Zenbook UX31A, UX305
+- Cube i9
+- Dell Inspiron 13 7000
+- Dell Venue 11 Pro (7140)
+- Dell Venue 8 Pro
+- HP Pavilion X360
+- HP Spectre x360 (Kaby Lake)
- Lenovo IdeaPad Yoga 13
-- Microsoft Surface Pro 2
-- Lenovo Yoga 2 Pro
+- Lenovo ThinkPad Twist
+- Lenovo X1 Carbon 2014 (rev2)
+- Lenovo X1 Tablet
- Lenovo Yoga 2 13" and 11"
+- Lenovo Yoga 2 Pro
+- Lenovo Yoga 460
- Lenovo Yoga 900
+- Microsoft Surface Pro 2
- Onda v975w
-- Dell Venue 8 Pro
-- Dell Venue 11 Pro (7140)
-- Lenovo ThinkPad Twist
-- MacBook Pro (8.2)
-- Lenovo X1 Carbon 2014 (rev2)
-- MacBook Air (6,2)
-- MacBook Air (4,2)
- Toshiba Portégé Z10t
- Toshiba Radius 11 L10WC10C
-- Dell Inspiron 13 7000
-- Cube i9
-- HP Pavilion X360
-- Asus Zenbook UX31A, UX305
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iio-sensor-proxy-2.0/configure new/iio-sensor-proxy-2.1/configure
--- old/iio-sensor-proxy-2.0/configure 2016-12-12 13:35:45.000000000 +0100
+++ new/iio-sensor-proxy-2.1/configure 2017-02-02 16:20:14.000000000 +0100
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for iio-sensor-proxy 2.0.
+# Generated by GNU Autoconf 2.69 for iio-sensor-proxy 2.1.
#
# Report bugs to .
#
@@ -580,8 +580,8 @@
# Identity of this package.
PACKAGE_NAME='iio-sensor-proxy'
PACKAGE_TARNAME='iio-sensor-proxy'
-PACKAGE_VERSION='2.0'
-PACKAGE_STRING='iio-sensor-proxy 2.0'
+PACKAGE_VERSION='2.1'
+PACKAGE_STRING='iio-sensor-proxy 2.1'
PACKAGE_BUGREPORT='hadess@hadess.net'
PACKAGE_URL=''
@@ -1287,7 +1287,7 @@
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures iio-sensor-proxy 2.0 to adapt to many kinds of systems.
+\`configure' configures iio-sensor-proxy 2.1 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1358,7 +1358,7 @@
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of iio-sensor-proxy 2.0:";;
+ short | recursive ) echo "Configuration of iio-sensor-proxy 2.1:";;
esac
cat <<\_ACEOF
@@ -1480,7 +1480,7 @@
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-iio-sensor-proxy configure 2.0
+iio-sensor-proxy configure 2.1
generated by GNU Autoconf 2.69
Copyright (C) 2012 Free Software Foundation, Inc.
@@ -1581,7 +1581,7 @@
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by iio-sensor-proxy $as_me 2.0, which was
+It was created by iio-sensor-proxy $as_me 2.1, which was
generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@
@@ -2460,7 +2460,7 @@
# Define the identity of the package.
PACKAGE='iio-sensor-proxy'
- VERSION='2.0'
+ VERSION='2.1'
cat >>confdefs.h <<_ACEOF
@@ -6226,7 +6226,7 @@
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by iio-sensor-proxy $as_me 2.0, which was
+This file was extended by iio-sensor-proxy $as_me 2.1, which was
generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -6283,7 +6283,7 @@
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
-iio-sensor-proxy config.status 2.0
+iio-sensor-proxy config.status 2.1
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iio-sensor-proxy-2.0/configure.ac new/iio-sensor-proxy-2.1/configure.ac
--- old/iio-sensor-proxy-2.0/configure.ac 2016-12-12 13:30:46.000000000 +0100
+++ new/iio-sensor-proxy-2.1/configure.ac 2017-02-02 16:20:08.000000000 +0100
@@ -1,6 +1,6 @@
AC_PREREQ(2.59)
-AC_INIT([iio-sensor-proxy], [2.0], [hadess@hadess.net])
+AC_INIT([iio-sensor-proxy], [2.1], [hadess@hadess.net])
AX_IS_RELEASE([git-directory])
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iio-sensor-proxy-2.0/data/80-iio-sensor-proxy.rules new/iio-sensor-proxy-2.1/data/80-iio-sensor-proxy.rules
--- old/iio-sensor-proxy-2.0/data/80-iio-sensor-proxy.rules 2016-12-10 16:52:07.000000000 +0100
+++ new/iio-sensor-proxy-2.1/data/80-iio-sensor-proxy.rules 2016-12-28 11:22:49.000000000 +0100
@@ -7,7 +7,7 @@
SUBSYSTEM=="hwmon", TEST=="light", ENV{IIO_SENSOR_PROXY_TYPE}="hwmon-als"
SUBSYSTEM=="iio", TEST=="in_accel_x_raw", TEST=="in_accel_y_raw", TEST=="in_accel_z_raw", ENV{IIO_SENSOR_PROXY_TYPE}="iio-poll-accel"
SUBSYSTEM=="iio", TEST=="scan_elements/in_accel_x_en", TEST=="scan_elements/in_accel_y_en", TEST=="scan_elements/in_accel_z_en", ENV{IIO_SENSOR_PROXY_TYPE}="iio-buffer-accel"
-SUBSYSTEM=="iio", TEST=="scan_elements/in_rot_from_north_magnetic_tilt_comp_en", ENV{IIO_SENSOR_PROXY_TYPE}="iio-compass"
+SUBSYSTEM=="iio", TEST=="scan_elements/in_rot_from_north_magnetic_tilt_comp_en", ENV{IIO_SENSOR_PROXY_TYPE}="iio-buffer-compass"
SUBSYSTEM=="iio", TEST=="in_illuminance_input", ENV{IIO_SENSOR_PROXY_TYPE}="iio-poll-als"
SUBSYSTEM=="iio", TEST=="scan_elements/in_intensity_both_en", ENV{IIO_SENSOR_PROXY_TYPE}="iio-buffer-als"
SUBSYSTEM=="input", ENV{ID_INPUT_ACCELEROMETER}=="1", ENV{IIO_SENSOR_PROXY_TYPE}="input-accel"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iio-sensor-proxy-2.0/data/iio-sensor-proxy.service.in new/iio-sensor-proxy-2.1/data/iio-sensor-proxy.service.in
--- old/iio-sensor-proxy-2.0/data/iio-sensor-proxy.service.in 2016-11-22 14:28:55.000000000 +0100
+++ new/iio-sensor-proxy-2.1/data/iio-sensor-proxy.service.in 2017-01-05 13:02:30.000000000 +0100
@@ -7,3 +7,13 @@
ExecStart=@sbindir@/iio-sensor-proxy
#Uncomment this to enable debug
#Environment="G_MESSAGES_DEBUG=all"
+
+# Lockdown
+ProtectSystem=true
+ProtectControlGroups=true
+ProtectHome=true
+ProtectKernelModules=true
+PrivateTmp=true
+PrivateNetwork=true
+MemoryDenyWriteExecute=true
+RestrictRealtime=true
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iio-sensor-proxy-2.0/data/net.hadess.SensorProxy.conf new/iio-sensor-proxy-2.1/data/net.hadess.SensorProxy.conf
--- old/iio-sensor-proxy-2.0/data/net.hadess.SensorProxy.conf 2015-06-08 15:08:29.000000000 +0200
+++ new/iio-sensor-proxy-2.1/data/net.hadess.SensorProxy.conf 2017-02-02 16:12:42.000000000 +0100
@@ -12,22 +12,22 @@
<!-- Only Geoclue can access the compass -->
<policy user="geoclue">
- <allow send_interface="net.hadess.SensorProxy.Compass" send_path="/net/hadess/SensorProxy/Compass"/>
- <allow send_interface="org.freedesktop.DBus.Introspectable" send_path="/net/hadess/SensorProxy/Compass"/>
- <allow send_interface="org.freedesktop.DBus.Properties" send_path="/net/hadess/SensorProxy/Compass"/>
- <allow send_interface="org.freedesktop.DBus.Peer" send_path="/net/hadess/SensorProxy/Compass"/>
+ <allow send_destination="net.hadess.SensorProxy" send_interface="net.hadess.SensorProxy.Compass" send_path="/net/hadess/SensorProxy/Compass"/>
+ <allow send_destination="net.hadess.SensorProxy" send_interface="org.freedesktop.DBus.Introspectable" send_path="/net/hadess/SensorProxy/Compass"/>
+ <allow send_destination="net.hadess.SensorProxy" send_interface="org.freedesktop.DBus.Properties" send_path="/net/hadess/SensorProxy/Compass"/>
+ <allow send_destination="net.hadess.SensorProxy" send_interface="org.freedesktop.DBus.Peer" send_path="/net/hadess/SensorProxy/Compass"/>
</policy>
<!-- Anyone can talk to the main interface -->
<policy context="default">
- <allow send_interface="net.hadess.SensorProxy"/>
- <allow send_interface="org.freedesktop.DBus.Introspectable"/>
- <allow send_interface="org.freedesktop.DBus.Properties"/>
- <allow send_interface="org.freedesktop.DBus.Peer"/>
- <deny send_interface="org.freedesktop.DBus.Introspectable" send_path="/net/hadess/SensorProxy/Compass"/>
- <deny send_interface="org.freedesktop.DBus.Properties" send_path="/net/hadess/SensorProxy/Compass"/>
- <deny send_interface="org.freedesktop.DBus.Peer" send_path="/net/hadess/SensorProxy/Compass"/>
- <!-- <deny send_interface="net.hadess.SensorProxy.Compass"/> -->
+ <allow send_destination="net.hadess.SensorProxy" send_interface="net.hadess.SensorProxy"/>
+ <allow send_destination="net.hadess.SensorProxy" send_interface="org.freedesktop.DBus.Introspectable"/>
+ <allow send_destination="net.hadess.SensorProxy" send_interface="org.freedesktop.DBus.Properties"/>
+ <allow send_destination="net.hadess.SensorProxy" send_interface="org.freedesktop.DBus.Peer"/>
+ <deny send_destination="net.hadess.SensorProxy" send_interface="org.freedesktop.DBus.Introspectable" send_path="/net/hadess/SensorProxy/Compass"/>
+ <deny send_destination="net.hadess.SensorProxy" send_interface="org.freedesktop.DBus.Properties" send_path="/net/hadess/SensorProxy/Compass"/>
+ <deny send_destination="net.hadess.SensorProxy" send_interface="org.freedesktop.DBus.Peer" send_path="/net/hadess/SensorProxy/Compass"/>
+ <!-- <deny send_destination="net.hadess.SensorProxy" send_interface="net.hadess.SensorProxy.Compass"/> -->
</policy>
</busconfig>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iio-sensor-proxy-2.0/docs/Makefile.in new/iio-sensor-proxy-2.1/docs/Makefile.in
--- old/iio-sensor-proxy-2.0/docs/Makefile.in 2016-12-12 13:35:46.000000000 +0100
+++ new/iio-sensor-proxy-2.1/docs/Makefile.in 2017-02-02 16:20:14.000000000 +0100
@@ -499,11 +499,11 @@
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
-@ENABLE_GTK_DOC_FALSE@maintainer-clean-local:
-@ENABLE_GTK_DOC_FALSE@install-data-local:
@ENABLE_GTK_DOC_FALSE@clean-local:
-@ENABLE_GTK_DOC_FALSE@uninstall-local:
+@ENABLE_GTK_DOC_FALSE@install-data-local:
@ENABLE_GTK_DOC_FALSE@distclean-local:
+@ENABLE_GTK_DOC_FALSE@uninstall-local:
+@ENABLE_GTK_DOC_FALSE@maintainer-clean-local:
clean: clean-am
clean-am: clean-generic clean-local mostlyclean-am
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iio-sensor-proxy-2.0/src/drv-fake-compass.c new/iio-sensor-proxy-2.1/src/drv-fake-compass.c
--- old/iio-sensor-proxy-2.0/src/drv-fake-compass.c 2015-06-12 14:16:10.000000000 +0200
+++ new/iio-sensor-proxy-2.1/src/drv-fake-compass.c 2017-02-02 15:52:42.000000000 +0100
@@ -34,8 +34,8 @@
if (g_strcmp0 (g_udev_device_get_subsystem (device), "input") != 0)
return FALSE;
- /* "Lid switch" is a random input device to latch onto */
- if (g_strcmp0 (g_udev_device_get_property (device, "NAME"), "\"Lid Switch\"") != 0)
+ /* "Power Button" is a random input device to latch onto */
+ if (g_strcmp0 (g_udev_device_get_property (device, "NAME"), "\"Power Button\"") != 0)
return FALSE;
g_debug ("Found fake compass at %s", g_udev_device_get_sysfs_path (device));
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iio-sensor-proxy-2.0/src/monitor-sensor.c new/iio-sensor-proxy-2.1/src/monitor-sensor.c
--- old/iio-sensor-proxy-2.0/src/monitor-sensor.c 2016-09-13 14:22:44.000000000 +0200
+++ new/iio-sensor-proxy-2.1/src/monitor-sensor.c 2017-02-02 16:03:56.000000000 +0100
@@ -108,12 +108,17 @@
if (g_variant_get_boolean (v)) {
g_variant_unref (v);
v = g_dbus_proxy_get_cached_property (iio_proxy, "CompassHeading");
- g_print ("=== Has compass (heading: %lf)\n",
- g_variant_get_double (v));
+ if (v) {
+ g_print ("=== Has compass (heading: %lf)\n",
+ g_variant_get_double (v));
+ g_variant_unref (v);
+ } else {
+ g_print ("=== Has compass (heading: unset)\n");
+ }
} else {
g_print ("=== No compass\n");
}
- g_variant_unref (v);
+ g_clear_pointer (&v, g_variant_unref);
}
static void
++++++ iio-sensor-proxy-rpmlintrc ++++++
addFilter("W: systemd-service-without-service_del_preun")
addFilter("W: systemd-service-without-service_del_postun")
addFilter("W: systemd-service-without-service_add_pre")
addFilter("W: systemd-service-without-service_add_post")
addFilter("W: suse-missing-rclink iio-sensor-proxy")