BB: uhttpd: do not configure TLS parameters if libustream-ssl is not present
authorJo-Philipp Wich <jow@openwrt.org>
Mon, 25 Aug 2014 12:46:35 +0000 (12:46 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Mon, 25 Aug 2014 12:46:35 +0000 (12:46 +0000)
A quite frequent problem after sysupgrading from an older, SSL enabled build
is that ustream-ssl is not installed so uhttpd fails to come up again due to
https listening directives in the preserved configuration.

Skip key/cert and ssl listen options when libustream-ssl.so is not present.

Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>
Backport of r42284

SVN-Revision: 42286

package/network/services/uhttpd/Makefile
package/network/services/uhttpd/files/uhttpd.init

index ba2ca55b04cea133a42353a50b5464c54a582641..a93b40a085789bb742f06fefdd3f2d698c002c75 100644 (file)
@@ -1,5 +1,5 @@
 #
-# Copyright (C) 2010-2013 Jo-Philipp Wich <jow@openwrt.org>
+# Copyright (C) 2010-2014 Jo-Philipp Wich <jow@openwrt.org>
 #
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
@@ -8,7 +8,7 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=uhttpd
-PKG_VERSION:=2014-06-11
+PKG_VERSION:=2014-08-25
 PKG_RELEASE=$(PKG_SOURCE_VERSION)
 
 PKG_SOURCE_PROTO:=git
index 608aa9d36b4908190510d1cb4bcd19cbc6e1992d..2e9460960614b74d027fede1d7994f7c3beb556a 100755 (executable)
@@ -109,7 +109,7 @@ start_instance()
        config_get UHTTPD_KEY  "$cfg" key  /etc/uhttpd.key
        config_get UHTTPD_CERT "$cfg" cert /etc/uhttpd.crt
 
-       [ -n "$https" ] && {
+       [ -f /lib/libustream-ssl.so ] && [ -n "$https" ] && {
                [ -f "$UHTTPD_CERT" -a -f "$UHTTPD_KEY" ] || {
                        config_foreach generate_keys cert
                }