[pulseaudio-commits] r1085 - /trunk/src/pulsecore/pstream.c
svnmailer-noreply at 0pointer.de
svnmailer-noreply at 0pointer.de
Fri Jul 14 16:00:58 PDT 2006
Author: lennart
Date: Sat Jul 15 01:00:57 2006
New Revision: 1085
URL: http://0pointer.de/cgi-bin/viewcvs.cgi?rev=1085&root=pulseaudio&view=rev
Log:
don't send SCM_CREDENTIALS on every sendmsg(), instead do it only on handshake
Modified:
trunk/src/pulsecore/pstream.c
Modified: trunk/src/pulsecore/pstream.c
URL: http://0pointer.de/cgi-bin/viewcvs.cgi/trunk/src/pulsecore/pstream.c?rev=1085&root=pulseaudio&r1=1084&r2=1085&view=diff
==============================================================================
--- trunk/src/pulsecore/pstream.c (original)
+++ trunk/src/pulsecore/pstream.c Sat Jul 15 01:00:57 2006
@@ -291,6 +291,7 @@
i->channel = channel;
i->offset = offset;
i->seek_mode = seek_mode;
+ i->with_creds = 0;
pa_memblock_ref(i->chunk.memblock);
@@ -317,9 +318,6 @@
p->write.descriptor[PA_PSTREAM_DESCRIPTOR_OFFSET_LO] = 0;
p->write.descriptor[PA_PSTREAM_DESCRIPTOR_SEEK] = 0;
-#ifdef SCM_CREDENTIALS
- p->send_creds_now = 1;
-#endif
} else {
assert(p->write.current->type == PA_PSTREAM_ITEM_MEMBLOCK && p->write.current->chunk.memblock);
@@ -329,11 +327,12 @@
p->write.descriptor[PA_PSTREAM_DESCRIPTOR_OFFSET_HI] = htonl((uint32_t) (((uint64_t) p->write.current->offset) >> 32));
p->write.descriptor[PA_PSTREAM_DESCRIPTOR_OFFSET_LO] = htonl((uint32_t) ((uint64_t) p->write.current->offset));
p->write.descriptor[PA_PSTREAM_DESCRIPTOR_SEEK] = htonl(p->write.current->seek_mode);
-
-#ifdef SCM_CREDENTIALS
- p->send_creds_now = 1;
-#endif
- }
+ }
+
+#ifdef SCM_CREDENTIALS
+ p->send_creds_now = p->write.current->with_creds;
+#endif
+
}
static int do_write(pa_pstream *p) {
More information about the pulseaudio-commits
mailing list