[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: Is KSharedConfig thread-safe ??
From:       "Paul Thomas" <thomaspu () gmail ! com>
Date:       2007-05-28 17:09:17
Message-ID: c52222ba0705281009m50776ffcn71dfe7501590130c () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


I stand corrected ;p

Paul

On 5/28/07, Thiago Macieira <thiago@kde.org> wrote:
>
> Paul Thomas wrote:
> >From that definition that they gave, I would say yes.
> >
> >Referencing the description of KSharedConfig in the api doc, it inherits
> >from two classes, KConfig and QSharedData.
> >
> >The Qt docs say that QSharedData is reentrant and KConfig is meant to
> > use shared memory, which would have to be thread safe. Then there's
> > KSharedConfig: provides a reference counted, shared memory variant of
> > KConfig.
> >
> >So definitely.
>
> Wrong conclusion.
>
> KSharedConfig means the configuration is shared. That means you can use
> multiple objects to access the same config, from different places.
> Everything will work as expected.
>
> But it's not thread-safe. It's not reentrant.
>
> --
> Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
>   PGP/GPG: 0x6EF45358; fingerprint:
>   E067 918B B660 DBD1 105C 966C 33F5 F005 6EF4 5358
>
>
> >> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to
> unsubscribe <<
>
>
>

[Attachment #5 (text/html)]

I stand corrected ;p<br><br>Paul<br><br><div><span class="gmail_quote">On 5/28/07, <b \
class="gmail_sendername">Thiago Macieira</b> &lt;<a \
href="mailto:thiago@kde.org">thiago@kde.org</a>&gt; wrote:</span><blockquote \
class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt \
0pt 0.8ex; padding-left: 1ex;"> Paul Thomas wrote:<br>&gt;From that definition that \
they gave, I would say yes.<br>&gt;<br>&gt;Referencing the description of \
KSharedConfig in the api doc, it inherits<br>&gt;from two classes, KConfig and \
QSharedData.<br> &gt;<br>&gt;The Qt docs say that QSharedData is reentrant and \
KConfig is meant to<br>&gt; use shared memory, which would have to be thread safe. \
Then there&#39;s<br>&gt; KSharedConfig: provides a reference counted, shared memory \
variant of <br>&gt; KConfig.<br>&gt;<br>&gt;So definitely.<br><br>Wrong \
conclusion.<br><br>KSharedConfig means the configuration is shared. That means you \
can use<br>multiple objects to access the same config, from different places. \
<br>Everything will work as expected.<br><br>But it&#39;s not thread-safe. It&#39;s \
not reentrant.<br><br>--<br> Thiago Macieira - thiago (AT) <a \
href="http://macieira.info">macieira.info</a> - thiago (AT) <a href="http://kde.org"> \
kde.org</a><br>&nbsp;&nbsp;PGP/GPG: 0x6EF45358; fingerprint:<br>&nbsp;&nbsp;E067 918B \
B660 DBD1 105C 966C 33F5 F005 6EF4 5358<br><br><br>&gt;&gt; Visit <a \
href="http://mail.kde.org/mailman/listinfo/kde-devel#unsub">http://mail.kde.org/mailman/listinfo/kde-devel#unsub
 </a> to unsubscribe &lt;&lt;<br><br><br></blockquote></div><br>



>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic