dbus/dbus dbus-string.c, 1.55, 1.56 dbus-message.c, 1.145,
1.146 dbus-marshal.h, 1.24, 1.25 dbus-internals.h, 1.44, 1.45
Havoc Pennington
hp at freedesktop.org
Sat Dec 18 16:11:22 PST 2004
Update of /cvs/dbus/dbus/dbus
In directory gabe:/tmp/cvs-serv31276/dbus
Modified Files:
dbus-string.c dbus-message.c dbus-marshal.h dbus-internals.h
Log Message:
2004-12-18 Havoc Pennington <hp at redhat.com>
* dbus/dbus-string.c (_dbus_string_validate_ascii): use ISASCII
macro
* dbus/dbus-message.c: fix a comment, and add a still-unused
not-implemented function
* dbus/dbus-marshal.h: fix comment
* dbus/dbus-internals.h (_DBUS_ISASCII): new macro
Index: dbus-string.c
===================================================================
RCS file: /cvs/dbus/dbus/dbus/dbus-string.c,v
retrieving revision 1.55
retrieving revision 1.56
diff -u -d -r1.55 -r1.56
--- dbus-string.c 27 Nov 2004 07:30:22 -0000 1.55
+++ dbus-string.c 19 Dec 2004 00:11:20 -0000 1.56
@@ -2394,8 +2394,7 @@
end = s + len;
while (s != end)
{
- if (_DBUS_UNLIKELY (*s == '\0' ||
- ((*s & ~0x7f) != 0)))
+ if (_DBUS_UNLIKELY (!_DBUS_ISASCII (*s)))
return FALSE;
++s;
Index: dbus-message.c
===================================================================
RCS file: /cvs/dbus/dbus/dbus/dbus-message.c,v
retrieving revision 1.145
retrieving revision 1.146
diff -u -d -r1.145 -r1.146
--- dbus-message.c 27 Nov 2004 07:30:22 -0000 1.145
+++ dbus-message.c 19 Dec 2004 00:11:20 -0000 1.146
@@ -2325,6 +2325,21 @@
return retval;
}
+/* Swap into our byte order if message isn't already.
+ * Done only when required, which allows the bus to avoid
+ * ever doing this as it routes messages.
+ */
+static void
+_dbus_message_ensure_our_byte_order (DBusMessage *message)
+{
+ if (message->byte_order == DBUS_COMPILER_BYTE_ORDER)
+ return;
+
+
+
+
+}
+
/**
* Gets arguments from a message given a variable argument list.
* The variable argument list should contain the type of the
@@ -5188,7 +5203,8 @@
/* FIXME because the service/interface/member/error names are already
* validated to be in the particular ASCII subset, UTF-8 validating
* them could be skipped as a probably-interesting optimization.
- * The UTF-8 validation definitely shows up in profiles.
+ * The UTF-8 validation shows up in callgrind-type profiles but
+ * not so much in sample/time-based profiles.
*/
static dbus_bool_t
decode_header_data (const DBusString *data,
Index: dbus-marshal.h
===================================================================
RCS file: /cvs/dbus/dbus/dbus/dbus-marshal.h,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -d -r1.24 -r1.25
--- dbus-marshal.h 10 Aug 2004 03:07:00 -0000 1.24
+++ dbus-marshal.h 19 Dec 2004 00:11:20 -0000 1.25
@@ -345,4 +345,4 @@
dbus_bool_t _dbus_type_is_valid (int typecode);
-#endif /* DBUS_PROTOCOL_H */
+#endif /* DBUS_MARSHAL_H */
Index: dbus-internals.h
===================================================================
RCS file: /cvs/dbus/dbus/dbus/dbus-internals.h,v
retrieving revision 1.44
retrieving revision 1.45
diff -u -d -r1.44 -r1.45
--- dbus-internals.h 26 Nov 2004 06:22:53 -0000 1.44
+++ dbus-internals.h 19 Dec 2004 00:11:20 -0000 1.45
@@ -198,6 +198,8 @@
#undef ABS
#define ABS(a) (((a) < 0) ? -(a) : (a))
+#define _DBUS_ISASCII(c) ((c) != '\0' && (((c) & ~0x7f) == 0))
+
typedef void (* DBusForeachFunction) (void *element,
void *data);
More information about the dbus-commit
mailing list