This is the mail archive of the
ecos-patches@sourceware.org
mailing list for the eCos project.
[Bug 1001544] services/curses/pdcurses: porting to GCC 4.6
- From: bugzilla-daemon at bugs dot ecos dot sourceware dot org
- To: ecos-patches at ecos dot sourceware dot org
- Date: Mon, 26 Mar 2012 17:11:09 +0100
- Subject: [Bug 1001544] services/curses/pdcurses: porting to GCC 4.6
- Auto-submitted: auto-generated
- References: <bug-1001544-104@http.bugs.ecos.sourceware.org/>
Please do not reply to this email. Use the web interface provided at:
http://bugs.ecos.sourceware.org/show_bug.cgi?id=1001544
--- Comment #3 from Sergei Gavrikov <sergei.gavrikov@gmail.com> 2012-03-26 17:11:07 BST ---
(In replay in comment #2)
> As a patch to the current code, it is fine, please commit.
Thanks for review, I'll process it.
> This is a separate issue really, but when I looked at it, I thought
> "that isn't thread-safe". But then I saw that it wasn't thread-safe
> before either, and then I saw that the main pdcurses code isn't
> thread-safe either. So I thought, that's fine, it's not meant to be
> thread-safe, although that isn't clear in the documentation.
>
> But then I see examples/pdcecos_app.c which seems to create a bunch of
> threads. But if curses isn't thread-safe, that doesn't seem like a
> great idea.
You're absolutely right. In those days I did not know that PDCurses is
not thread safe (though and that serial driver is not thread-safe too).
And now I even found a separate record about (in PDCurses HISTORY file)
- Removed the PDC_THREAD_BUILD stuff, which has never worked. For the
record: PDCurses is not thread-safe. Neither is ncurses; and the
X/Open curses spec explicitly makes it a non-requirement.
> In fact I don't really understand the purpose of pdcecos_app.c - why
> would users need to start curses threads in a special and unusual way?
> If it's just because of the need to create a per-thread data index,
> then there are other ways that could be dealt with.
I think it is better to remove that `example' folder, which can mislead
someone else. So, I would remove that example in the next commit. I see
that native PDcurses demos (or eCos PDCurses tests) are more than enough
for the package.
Thank you for your all points.
Sergei
> Jifl
--
Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.