Permalink
Commits on Nov 20, 2012
  1. linux: use /proc/cpuinfo for CPU frequency

    bnoordhuis committed Oct 20, 2012
    Obtain the CPU frequency from /proc/cpuinfo because there may not be any
    cpufreq info available in /sys. This also means that the reported CPU speed
    from now on is the *maximum* speed, not the *actual* speed the CPU runs at.
    
    This change only applies to x86 because ARM and MIPS don't report that
    information in /proc/cpuinfo.
    
    Fixes #588.
    
    This is a back-port of commit 775064a from the master branch.
Commits on Nov 14, 2012
  1. windows: map WSAESHUTDOWN to UV_EPIPE

    bnoordhuis committed Nov 14, 2012
    This is a back-port of commit 483043b from the master branch.
Commits on Nov 9, 2012
  1. build: use link_settings, fix typo

    bnoordhuis committed Nov 9, 2012
    * Use link_settings instead of direct_dependent_settings.
    * Fix typo: s/ldlags/ldflags/
    
    Pointed out by a certain R.L. Dahl of San Francisco, CA.
    
    Fixes #618.
Commits on Nov 7, 2012
Commits on Nov 5, 2012
  1. test: remove unnecessary #ifdef _WIN32

    bnoordhuis committed Nov 5, 2012
    This is a back-port of commit 4d17337 from the master branch.
  2. windows: un-break the build

    piscisaureus committed Nov 5, 2012
    It was broken in fb64948.
Commits on Nov 3, 2012
  1. unix: do not set environ unless one is provided

    AvianFlu committed with bnoordhuis Nov 1, 2012
    Currently, `uv_spawn` will set `environ` to the value of `options.env`, even if
    `options.env` is `NULL`.  This results in child processes for whom `environ ==
    NULL`, which can cause a variety of unexpected issues.
    
    This is a back-port of commit 1d85815 from the master branch.
Commits on Oct 25, 2012
  1. include: fix ngx_queue_foreach() macro

    bnoordhuis committed Oct 25, 2012
    Guard against the possibility that the queue is emptied while we're iterating
    over it. Simple test case:
    
      #include "ngx-queue.h"
      #include <assert.h>
    
      int main(void) {
        ngx_queue_t h;
        ngx_queue_t v[2];
        ngx_queue_t* q;
        unsigned n = 0;
        ngx_queue_init(&h);
        ngx_queue_insert_tail(&h, v + 0);
        ngx_queue_insert_tail(&h, v + 1);
        ngx_queue_foreach(q, &h) {
          ngx_queue_remove(v + 0);
          ngx_queue_remove(v + 1);
          n++;
        }
        assert(n == 1); // *not* 2
        return 0;
      }
    
    Fixes #605.
Commits on Oct 22, 2012
  1. linux: update comm field in uv_set_process_title()

    bnoordhuis committed Oct 22, 2012
    Makes the new process name visible in both `ps` and `ps a`, with the caveat
    that `ps` will only print the first 16 characters.
    
    Before this commit, `ps` kept reporting the old process name.
Commits on Oct 10, 2012
  1. windows: fix application crashed popup in debug version

    piscisaureus committed Oct 10, 2012
    This is a backport of 2 patches by Ting-Yu Lin and Hiroaki Nakamura.
Commits on Sep 22, 2012
Commits on Sep 21, 2012
Commits on Sep 15, 2012
  1. linux: improve /proc/cpuinfo parser

    bnoordhuis committed Aug 14, 2012
    Make uv_cpu_info() understand the ARM and MIPS versions of /proc/cpuinfo,
    it only knew how to deal with the x86 version
    
    This commit also fixes a buglet where uv_cpu_info() reported the maximum CPU
    frequency instead of the actual CPU frequency. That is, before this commit
    `out/Debug/run-tests platform_output | grep speed | sort | uniq -c` on my
    system always reported:
    
          8   speed: 3400
    
    Now it reports (for example):
    
          2   speed: 3400
          6   speed: 1600
    
    In other words, two CPUs are running at full speed while the others have been
    scaled back because they're mostly idle.
    
    This is a back-port of commit 54bfb66 from the master branch.
    
    Fixes #526.
Commits on Sep 14, 2012
Commits on Sep 11, 2012
  1. unix: put child process stdio fds in blocking mode

    bnoordhuis committed Sep 11, 2012
    Remove the O_NONBLOCK flag from file descriptors 0-2, most applications don't
    expect EAGAIN errors when dealing with stdio.
Commits on Sep 10, 2012
  1. unix: fix EMFILE busy loop

    bnoordhuis committed Sep 10, 2012
    Don't spin in epoll_wait() / kevent() / port_getn() / etc. when we can't
    accept() a new connection due to having reached the file descriptor limit.
    Pass the error to the connection_cb and let the libuv user deal with it.
Commits on Sep 3, 2012
  1. sunos: don't set TCP_KEEPALIVE

    bnoordhuis committed Sep 3, 2012
    The system headers advertise the socket option but the actual syscall fails
    with ENOPROTOOPT.
    
    Fixes nodejs/node-v0.x-archive#3937.
Commits on Aug 30, 2012
Commits on Aug 25, 2012
  1. unix: fix memory leak in udp.c

    bnoordhuis committed Aug 25, 2012
    Some memory was leaked when the uv_udp_t handle was closed when there were
    in-flight send requests with a heap allocated buffer list.
    
    That doesn't happen much in practice. In the common case (writing < 5 buffers),
    the buffer list is stored inside the uv_udp_send_t structure, not allocated on
    the heap.
Commits on Aug 22, 2012
  1. unix: map errno ESPIPE

    bnoordhuis committed Aug 22, 2012
Commits on Aug 20, 2012
  1. windows: fix uninitialized memory access in uv_update_time()

    piscisaureus committed Aug 20, 2012
    uv_update_time does not overwrite the high 32 bits of uv_loop_t.time.
    It merely increments it by one when the low 32 bits have wrapped. That
    means that `time` needs to be initialized to zero before
    uv_update_time() is called for the first time.
  2. unix, windows: fix memory corruption in fs-poll.c

    bnoordhuis committed Aug 20, 2012
    uv_fs_poll_t has an embedded uv_timer_t handle that got closed at a time when
    the memory of the encapsulating handle might already have been deallocated.
    
    Solve that by moving the poller's state into a structure that is allocated on
    the heap and can be freed independently.
  3. unix: fix const correctness compiler warning

    bnoordhuis committed Aug 7, 2012
    This is a back-port of commit f97c80f from the master branch.
Commits on Aug 18, 2012
  1. unix: fix integer overflow in uv_hrtime

    timholy committed with piscisaureus Aug 17, 2012
    Conversion to nanoseconds was overflowing with 32-bit builds.
Commits on Aug 16, 2012
  1. sunos: fix uv_cpu_info() on x86_64

    bnoordhuis committed Aug 16, 2012
    kstat_data_lookup("clock_Mhz") returns a KSTAT_DATA_INT32 on i386 but a
    KSTAT_DATA_INT64 on x86_64.
Commits on Aug 15, 2012
Commits on Aug 13, 2012
  1. build: rework -fvisibility=hidden detection

    bnoordhuis committed Aug 13, 2012
    Make the gcc_version macro conform with what node.js and v8 use. Important
    because node.js's common.gypi is going to export it soon.
Commits on Aug 8, 2012
Commits on Aug 3, 2012
  1. windows: map WSANO_DATA to UV_ENOENT

    piscisaureus committed Aug 3, 2012
    This improves uv_getaddrinfo error reporting.