aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/dix/dixfonts.c
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2012-07-10 14:56:29 +0200
committermarha <marha@users.sourceforge.net>2012-07-10 14:56:29 +0200
commitd137057fd13e83ec15ab416c7fe774741da06047 (patch)
treef4b38caa4f3ecb983f00e84f4f4d8d66699ecbc5 /xorg-server/dix/dixfonts.c
parentc29d91cfd8df084f16d0d2dfa82c3a86f7719a73 (diff)
downloadvcxsrv-d137057fd13e83ec15ab416c7fe774741da06047.tar.gz
vcxsrv-d137057fd13e83ec15ab416c7fe774741da06047.tar.bz2
vcxsrv-d137057fd13e83ec15ab416c7fe774741da06047.zip
fontconfig mesa xserver git update 10 Jul 2012
Diffstat (limited to 'xorg-server/dix/dixfonts.c')
-rw-r--r--xorg-server/dix/dixfonts.c26
1 files changed, 14 insertions, 12 deletions
diff --git a/xorg-server/dix/dixfonts.c b/xorg-server/dix/dixfonts.c
index dd9331195..ad218604d 100644
--- a/xorg-server/dix/dixfonts.c
+++ b/xorg-server/dix/dixfonts.c
@@ -753,11 +753,12 @@ doListFontsAndAliases(ClientPtr client, LFclosurePtr c)
for (i = 0; i < nnames; i++)
stringLens += (names->length[i] <= 255) ? names->length[i] : 0;
- memset(&reply, 0, sizeof(xListFontsReply));
- reply.type = X_Reply;
- reply.length = bytes_to_int32(stringLens + nnames);
- reply.nFonts = nnames;
- reply.sequenceNumber = client->sequence;
+ reply = (xListFontsReply) {
+ .type = X_Reply,
+ .length = bytes_to_int32(stringLens + nnames),
+ .nFonts = nnames,
+ .sequenceNumber = client->sequence
+ };
bufptr = bufferStart = malloc(reply.length << 2);
@@ -782,7 +783,7 @@ doListFontsAndAliases(ClientPtr client, LFclosurePtr c)
reply.length = bytes_to_int32(stringLens + nnames);
client->pSwapReplyFunc = ReplySwapVector[X_ListFonts];
WriteSwappedDataToClient(client, sizeof(xListFontsReply), &reply);
- (void) WriteToClient(client, stringLens + nnames, bufferStart);
+ WriteToClient(client, stringLens + nnames, bufferStart);
free(bufferStart);
bail:
@@ -1020,7 +1021,7 @@ doListFontsWithInfo(ClientPtr client, LFWIclosurePtr c)
pFP++;
}
WriteSwappedDataToClient(client, length, reply);
- (void) WriteToClient(client, namelen, name);
+ WriteToClient(client, namelen, name);
if (pFontInfo == &fontInfo) {
free(fontInfo.props);
free(fontInfo.isStringProp);
@@ -1030,11 +1031,12 @@ doListFontsWithInfo(ClientPtr client, LFWIclosurePtr c)
}
finish:
length = sizeof(xListFontsWithInfoReply);
- memset((char *) &finalReply, 0, sizeof(xListFontsWithInfoReply));
- finalReply.type = X_Reply;
- finalReply.sequenceNumber = client->sequence;
- finalReply.length = bytes_to_int32(sizeof(xListFontsWithInfoReply)
- - sizeof(xGenericReply));
+ finalReply = (xListFontsWithInfoReply) {
+ .type = X_Reply,
+ .sequenceNumber = client->sequence,
+ .length = bytes_to_int32(sizeof(xListFontsWithInfoReply)
+ - sizeof(xGenericReply))
+ };
WriteSwappedDataToClient(client, length, &finalReply);
bail:
ClientWakeup(client);