summaryrefslogtreecommitdiff
path: root/usr.sbin/unbound/util/mini_event.c
diff options
context:
space:
mode:
authorStuart Henderson <sthen@cvs.openbsd.org>2016-03-05 14:40:36 +0000
committerStuart Henderson <sthen@cvs.openbsd.org>2016-03-05 14:40:36 +0000
commita7a76137d87f4fe8c33a9bda24805fbbd52f126b (patch)
tree44c8b68e7372c785777cba35eb0902a5bc0bd4fe /usr.sbin/unbound/util/mini_event.c
parentaf687625218080f82b0fecdf0819b0233f881cd6 (diff)
update to unbound 1.5.8, ok florian@ jung@
Diffstat (limited to 'usr.sbin/unbound/util/mini_event.c')
-rw-r--r--usr.sbin/unbound/util/mini_event.c33
1 files changed, 15 insertions, 18 deletions
diff --git a/usr.sbin/unbound/util/mini_event.c b/usr.sbin/unbound/util/mini_event.c
index f66214ddb8f..98d15f677b0 100644
--- a/usr.sbin/unbound/util/mini_event.c
+++ b/usr.sbin/unbound/util/mini_event.c
@@ -21,16 +21,16 @@
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
- * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE
- * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- * POSSIBILITY OF SUCH DAMAGE.
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
+ * TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
*/
@@ -79,13 +79,13 @@ settime(struct event_base* base)
return -1;
}
#ifndef S_SPLINT_S
- *base->time_secs = (uint32_t)base->time_tv->tv_sec;
+ *base->time_secs = (time_t)base->time_tv->tv_sec;
#endif
return 0;
}
/** create event base */
-void *event_init(uint32_t* time_secs, struct timeval* time_tv)
+void *event_init(time_t* time_secs, struct timeval* time_tv)
{
struct event_base* base = (struct event_base*)malloc(
sizeof(struct event_base));
@@ -261,12 +261,9 @@ void event_base_free(struct event_base* base)
{
if(!base)
return;
- if(base->times)
- free(base->times);
- if(base->fds)
- free(base->fds);
- if(base->signals)
- free(base->signals);
+ free(base->times);
+ free(base->fds);
+ free(base->signals);
free(base);
}