This is the mail archive of the
cygwin@cygwin.com
mailing list for the Cygwin project.
Re: setpriority() and PRIO_PROCESS under Cygwin
- From: "Ehud Karni" <ehud at unix dot mvs dot co dot il>
- To: garbage_collector at telia dot com
- Cc: cygwin at cygwin dot com
- Date: Sun, 12 Oct 2003 22:50:55 +0200
- Subject: Re: setpriority() and PRIO_PROCESS under Cygwin
- Organization: Mivtach-Simon Insurance agencies
- References: <NGBBLLIAMFLGJEOAJCCEEEDBDFAA.garbage_collector@telia.com>
- Reply-to: ehud at unix dot mvs dot co dot il
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Sun, 12 Oct 2003 15:21:41 +0200, Hannu E K Nevalainen <garbage_collector@telia.com> wrote:
>
> >+> setpriority/getpriority are not implemented in Cygwin.
>
> This means; use __CYGWIN__ or some such to create conditional (i.e.
> exclusion of) compiling of those parts of the source.
I did it once like this (code from a program I no longer use):
#ifdef __CYGWIN__
#include <windows.h> /* for some specific Windoz calls */
#endif /* __CYGWIN__ */
#ifdef __CYGWIN__
{
HANDLE WinId ;
WinId = GetCurrentProcess ( ) ; /* get my Windows HANDLE */
SetPriorityClass ( WinId , REALTIME_PRIORITY_CLASS ) ; /* set priority to REAL TIME CLASS */
}
#endif /* __CYGWIN__ */
Ehud.
- --
Ehud Karni Tel: +972-3-7966-561 /"\
Mivtach - Simon Fax: +972-3-7966-667 \ / ASCII Ribbon Campaign
Insurance agencies (USA) voice mail and X Against HTML Mail
http://www.mvs.co.il FAX: 1-815-5509341 / \
GnuPG: 98EA398D <http://www.keyserver.net/> Better Safe Than Sorry
-----BEGIN PGP SIGNATURE-----
Comment: use http://www.keyserver.net/ to get my key (and others)
iD8DBQE/ib6uLFvTvpjqOY0RAtdqAJ9HKOprp8ZnzJdrADlQ3eQxYYOfTACeJ9UZ
GPrUJElEq3ByYMSLLamRal4=
=Cmx0
-----END PGP SIGNATURE-----
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/