1. 07 Jun, 2018 1 commit
    • Ting-Wei Lan's avatar
      build: Define MAJOR_IN_TYPES when major is defined in sys/types.h · c61f01f0
      Ting-Wei Lan authored
      Autoconf macro AC_HEADER_MAJOR doesn't define a macro in config.h when
      major is defined in sys/types.h. This was not a problem because major
      is assumed to be always available. However, commit aefffa3f
      changes this assumption in order to fix build on systems without major,
      which causes code using major to be disabled on systems putting major
      in sys/types.h.
      
      This commit defines a new macro MAJOR_IN_TYPES for both autotools and
      meson builds to make major useful on these systems again.
      c61f01f0
  2. 02 Feb, 2018 1 commit
  3. 28 Nov, 2017 1 commit
  4. 11 Sep, 2017 1 commit
    • Daniel Macks's avatar
      Avoid setting unused variables (-Wself-assign) · 190f64a0
      Daniel Macks authored
      Setting a variable and then assigning it to itself avoids
      -Wunused-but-set-variable but this specific trick is now caught by
      -Wself-assign. Instead, actually use the value or don't bother
      assigning it at all:
      
      gdbusauth.c: call g_data_input_stream_read_byte() in void context
      gdbusauthmechanismsha1.c: value is actually used
      gdbusmessage.c: use consistent preprocessor-token protection
      gthreadedresolver.c: skip over bytes in data blob
      httpd.c: do something useful with the value
      
      https://bugzilla.gnome.org/show_bug.cgi?id=745723
      190f64a0
  5. 03 Aug, 2017 1 commit
    • Philip Withnall's avatar
      Consistently save errno immediately after the operation setting it · 5cddde1f
      Philip Withnall authored
      Prevent the situation where errno is set by function A, then function B
      is called (which is typically _(), but could be anything else) and it
      overwrites errno, then errno is checked by the caller.
      
      errno is a horrific API, and we need to be careful to save its value as
      soon as a function call (which might set it) returns. i.e. Follow the
      pattern:
        int errsv, ret;
        ret = some_call_which_might_set_errno ();
        errsv = errno;
      
        if (ret < 0)
          puts (strerror (errsv));
      
      This patch implements that pattern throughout GLib. There might be a few
      places in the test code which still use errno directly. They should be
      ported as necessary. It doesn’t modify all the call sites like this:
        if (some_call_which_might_set_errno () && errno == ESOMETHING)
      since the refactoring involved is probably more harmful than beneficial
      there. It does, however, refactor other call sites regardless of whether
      they were originally buggy.
      
      https://bugzilla.gnome.org/show_bug.cgi?id=785577
      5cddde1f
  6. 21 Jun, 2017 1 commit
  7. 29 May, 2017 1 commit
  8. 28 Apr, 2017 1 commit
  9. 10 Apr, 2017 1 commit
  10. 22 Nov, 2016 3 commits
  11. 12 Oct, 2016 1 commit
  12. 21 Apr, 2015 1 commit
  13. 30 Oct, 2014 1 commit
  14. 24 Jul, 2014 1 commit
  15. 23 Jul, 2014 1 commit
  16. 09 Jul, 2014 3 commits
  17. 07 Jul, 2014 1 commit
  18. 23 May, 2014 1 commit
  19. 09 May, 2014 1 commit
    • Lukasz Skalski's avatar
      gio: cleanup gdbusmessage.c file · 7c205ae9
      Lukasz Skalski authored
      * removed passing GError to ensure_input_padding() function
        - it was necessary before commit 3e5214c1
        when we used GData*Streams and GMemoryInputStream with
        g_seekable_seek() - now it's useless,
      
      * removed checking return value of ensure_input_padding()
        function - in previous implementation (like above)
        g_seekable_seek() could return FALSE - now it's always TRUE,
      
      * removed passing GError to g_memory_buffer_read_*() functions
        and checking returned value - it also has been inherited after
        old implementation with g_data_input_stream_read_*() functions
        - now it's also useless
      
      * cleaned up code formatting,
      
      https://bugzilla.gnome.org/show_bug.cgi?id=729875
      7c205ae9
  20. 01 Feb, 2014 2 commits
  21. 31 Jan, 2014 1 commit
  22. 20 Nov, 2013 1 commit
    • Dan Winship's avatar
      Replace #ifdef HAVE_UNISTD_H checks with #ifdef G_OS_UNIX · 158dde05
      Dan Winship authored
      In Windows development environments that have it, <unistd.h> is mostly
      just a wrapper around several other native headers (in particular,
      <io.h>, which contains read(), close(), etc, and <process.h>, which
      contains getpid()). But given that some Windows dev environments don't
      have <unistd.h>, everything that uses those functions on Windows
      already needed to include the correct Windows header as well, and so
      there is never any point to including <unistd.h> on Windows.
      
      Also, remove some <unistd.h> includes (and a few others) that were
      unnecessary even on unix.
      
      https://bugzilla.gnome.org/show_bug.cgi?id=710519
      158dde05
  23. 18 Nov, 2013 1 commit
  24. 27 Sep, 2013 1 commit
  25. 21 May, 2013 1 commit
    • Dan Winship's avatar
      Use 'dumb quotes' rather than `really dumb quotes' · 4b94c083
      Dan Winship authored
      Back in the far-off twentieth century, it was normal on unix
      workstations for U+0060 GRAVE ACCENT to be drawn as "‛" and for U+0027
      APOSTROPHE to be drawn as "’". This led to the convention of using
      them as poor-man's ‛smart quotes’ in ASCII-only text.
      
      However, "'" is now universally drawn as a vertical line, and "`" at a
      45-degree angle, making them an `odd couple' when used together.
      
      Unfortunately, there are lots of very old strings in glib, and also
      lots of new strings in which people have kept up the old tradition,
      perhaps entirely unaware that it used to not look stupid.
      
      Fix this by just using 'dumb quotes' everywhere.
      
      https://bugzilla.gnome.org/show_bug.cgi?id=700746
      4b94c083
  26. 01 Apr, 2013 1 commit
  27. 07 Mar, 2013 1 commit
  28. 13 Jan, 2013 1 commit
  29. 30 Nov, 2012 1 commit
  30. 29 Nov, 2012 1 commit
  31. 15 Nov, 2012 1 commit
  32. 10 Apr, 2012 2 commits
    • Will Thompson's avatar
      GDBusMessage: do not align for grandchildren of empty arrays. · 113f4abb
      Will Thompson authored
      D-Bus arrays are serialized as follows:
      
      1. align to a 4-byte boundary (for the length)
      2. uint32: the length of the serialized body in bytes
      3. padding for the alignment of the body type (not included in the length)
      4. the body.
      
      Note that 3. is a no-op unless the body type is an 8-byte aligned type
      (uint64, int64, double, struct, dict_entry), since you are always on a
      4-byte boundary from aligning and writing the length.
      
      So, an empty aax (that is, an array containing zero arrays of int64)
      is serialized as follows:
      
      1. align to a 4-byte boundary
      2. length of the contents of this (empty) array, in bytes (0)
      3. align to a 4-byte boundary (the child array's alignment requirement)
      4. there is no body.
      
      But previously, GDBus would recurse in step three to align not just for
      the type of the child array, but for the nonexistent child array's
      contents. This only affects the algorithm when the grandchild type has
      8-byte alignment and the reader happened to not already be on an 8-byte
      boundary, in which case 4 bytes were spuriously skipped.
      
      https://bugzilla.gnome.org/show_bug.cgi?id=673612Signed-off-by: 's avatarDavid Zeuthen <davidz@redhat.com>
      113f4abb
    • Will Thompson's avatar
      e28d3ef9
  33. 05 Apr, 2012 1 commit
  34. 31 Mar, 2012 1 commit