From eb9d3b8d6d70b593e80fb50650b5e33520ea296d Mon Sep 17 00:00:00 2001 From: Hyungdeuk Kim Date: Mon, 19 Aug 2013 15:15:50 +0900 Subject: fix prevent issues --- heynoti.c | 6 ++++-- packaging/heynoti.spec | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/heynoti.c b/heynoti.c index 7f92c9c..bf1f437 100755 --- a/heynoti.c +++ b/heynoti.c @@ -264,10 +264,12 @@ static int __handle_event(int fd) return -1; if (ie.len > 0u) { - read(fd, name, (ie.len > FILENAME_MAX) ? (size_t)FILENAME_MAX : (size_t) ie.len); + r = read(fd, name, (ie.len > FILENAME_MAX) ? (size_t)FILENAME_MAX : (size_t) ie.len); } - r = read(fd, &ie, sizeof(ie)); + if(r > 0) { + r = read(fd, &ie, sizeof(ie)); + } } return 0; diff --git a/packaging/heynoti.spec b/packaging/heynoti.spec index 56295d1..d9cc28c 100644 --- a/packaging/heynoti.spec +++ b/packaging/heynoti.spec @@ -2,7 +2,7 @@ Name: heynoti Version: 0.0.2 -Release: 39 +Release: 40 License: Apache License, Version 2.0 Summary: HEY (ligHt Easy speedy) notification library Group: System/Libraries -- cgit v1.2.3 From 6060be6994a7a5e46790f0187f023b5dad18429a Mon Sep 17 00:00:00 2001 From: Hyungdeuk Kim Date: Wed, 25 Sep 2013 09:53:50 +0900 Subject: install license file --- packaging/heynoti.spec | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/packaging/heynoti.spec b/packaging/heynoti.spec index d9cc28c..891f7d9 100644 --- a/packaging/heynoti.spec +++ b/packaging/heynoti.spec @@ -2,7 +2,7 @@ Name: heynoti Version: 0.0.2 -Release: 40 +Release: 41 License: Apache License, Version 2.0 Summary: HEY (ligHt Easy speedy) notification library Group: System/Libraries @@ -37,7 +37,8 @@ make %{?_smp_mflags} %install %make_install - +mkdir -p %{buildroot}/usr/share/license +install LICENSE %{buildroot}/usr/share/license/%{name} mkdir -p %{buildroot}/opt/share/noti %post -p /sbin/ldconfig @@ -52,6 +53,7 @@ mkdir -p %{buildroot}/opt/share/noti %{_libdir}/libheynoti.so.0.0.2 %{_bindir}/heynotitool %attr(1755,root,root) /opt/share/noti +/usr/share/license/%{name} %files devel -- cgit v1.2.3