Browse Source

Merge 1.0

Brian Aker 12 years ago
parent
commit
fcfdb7705a

+ 2 - 0
ChangeLog

@@ -26,6 +26,8 @@
 
 1.0.6
 * strlen() of zero on name passed for instance did not result in a connection to localhost (which the php driver thought would happen).
+* Fix regression in log not updating time on all platforms.
+* Fix issue where pecl php wasn't passing a null string to get default host.
 
 1.0.5 Mon Apr 15 06:36:05 EDT 2013
 * Fix for log_fn

+ 1 - 2
libgearman-server/timer.cc

@@ -76,8 +76,7 @@ static __attribute__((noreturn)) void* current_epoch_handler(void*)
     {
       gearmand_perror(errno, "poll");
     }
-
-    if (active_fd > 0)
+    else
     {
       if (fds[1].revents)
       {

+ 1 - 0
libgearman/actions.cc

@@ -42,6 +42,7 @@
 #include <libgearman/result.hpp>
 
 #include "libgearman/assert.hpp"
+#include "libgearman/vector.h"
 
 #include <memory>
 

+ 1 - 0
libgearman/add.cc

@@ -45,6 +45,7 @@
 
 #include "libgearman/assert.hpp"
 
+#include "libgearman/vector.h"
 #include "libgearman/uuid.hpp"
 #include "libhashkit-1.0/hashkit.h"
 

+ 2 - 8
libgearman/connection.cc

@@ -298,14 +298,8 @@ void gearman_connection_st::set_host(const char *host_, const char* service_)
 {
   reset_addrinfo();
 
-  if (host_)
-  {
-    size_t string_len= strlen(host_);
-    if (string_len == 0)
-    {
-      host_= GEARMAN_DEFAULT_TCP_HOST;
-    }
-  }
+  if (host_ and host_[0])
+  { }
   else
   {
     host_= GEARMAN_DEFAULT_TCP_HOST;

+ 3 - 1
libgearman/function/base.hpp

@@ -2,7 +2,7 @@
  * 
  *  Gearmand client and server library.
  *
- *  Copyright (C) 2011 Data Differential, http://datadifferential.com/
+ *  Copyright (C) 2011-2013 Data Differential, http://datadifferential.com/
  *  All rights reserved.
  *
  *  Redistribution and use in source and binary forms, with or without
@@ -40,6 +40,8 @@
 #include <cstring>
 #include <memory>
 
+#include "libgearman/vector.h"
+
 enum gearman_function_error_t {
   GEARMAN_FUNCTION_SUCCESS= GEARMAN_SUCCESS,
   GEARMAN_FUNCTION_INVALID_ARGUMENT= GEARMAN_INVALID_ARGUMENT,

+ 1 - 0
libgearman/include.am

@@ -30,6 +30,7 @@ noinst_HEADERS+= libgearman/ostream.hpp
 noinst_HEADERS+= libgearman/error_code.h
 noinst_HEADERS+= libgearman/command.hpp
 noinst_HEADERS+= libgearman/uuid.hpp
+noinst_HEADERS+= libgearman/vector.h
 noinst_HEADERS+= \
 		 libgearman/actions.hpp \
 		 libgearman/add.hpp \

+ 2 - 1
libgearman/interface/universal.hpp

@@ -2,7 +2,7 @@
  * 
  *  Gearmand client and server library.
  *
- *  Copyright (C) 2011 Data Differential, http://datadifferential.com/
+ *  Copyright (C) 2011-2013 Data Differential, http://datadifferential.com/
  *  Copyright (C) 2008 Brian Aker, Eric Day
  *  All rights reserved.
  *
@@ -41,6 +41,7 @@
 #include "libgearman/allocator.hpp" 
 #include "libgearman/server_options.hpp"
 #include "libgearman/interface/packet.hpp"
+#include "libgearman/vector.h" 
 
 /**
   @todo this is only used by the server and should be made private.

+ 1 - 0
libgearman/job.cc

@@ -41,6 +41,7 @@
 #include <libgearman/common.h>
 
 #include "libgearman/assert.hpp"
+#include "libgearman/vector.h"
 
 #include <cstdio>
 #include <cstring>

+ 1 - 1
libgearman/log.hpp

@@ -2,7 +2,7 @@
  * 
  *  Gearmand client and server library.
  *
- *  Copyright (C) 2011 Data Differential, http://datadifferential.com/
+ *  Copyright (C) 2011-2013 Data Differential, http://datadifferential.com/
  *  Copyright (C) 2008 Brian Aker, Eric Day
  *  All rights reserved.
  *

Some files were not shown because too many files changed in this diff