looks_like_text(): Allow '\b' to appear in text files. (cherry picked from commit 48e2a57)
Also add -D switches to not pointlessly include entries for directories in the zip files.
Patch from bug #572252.
The patch ensures that multibyte character sets are properly nul-terminated. This is an issue because the documentation claims to return a "nul-terminated" string and users of the API assume that means a proper nul-termination in the resulting character set. I looked at Pidgin and GStreamer code and found at least 3 cases where this was happening. This patch also reverts the documentation change from 8c93617 as that is now no longer necessary.
THere is effectively no nul-termination for multibyte characters.
Since returning exactly one match has special significance, don't give up matching before we've found at least 2 types. Also, make sure that we don't return the same mime type more than once. Bug 541236.
Correctly unref the pclass. Patch by Chris Wilson and Tim Janik. https://bugzilla.gnome.org/show_bug.cgi?id=350200
Store whether the object has a toggleref before decrementing the refcount to prevent race condition when two threads simultaneously try to unref an object with a refcount of 2. Patch by Antoine Tremblay. https://bugzilla.gnome.org/show_bug.cgi?id=551706
If __val doesn't exist, we shouldn't do any other checks.
This avoids a bunch of code and makes construction of simple objects faster. Object construction performance improvement: Non-Threaded Threaded Simple: 14% 5% Complex: -1.1% -2.2% Other tests stable. https://bugzilla.gnome.org/show_bug.cgi?id=557100
If the class has no properties there could be no notification anyway. This is an important optimization for construction of simple objects. Object construction performance improvement: Non-Threaded Threaded Simple: 84% 91% Complex: -1.4% -0.6% Other tests stable. https://bugzilla.gnome.org/show_bug.cgi?id=557100
We can't support that, because that would cause the CLASS_HAS_PROPS_FLAG class flag to not be correct.