Switching groups with newgrp - how to get the new group with |GetTokenInformation()| ?
Hi! If I switch the current user's group with /usr/bin/newgrp, how can a (native) Win32 process use |GetTokenInformation(GetCurrentThreadToken(), ...)| to find out which group is the new "current group" (e.g. which |TokenInformationClass| should I use) ? Bye, Roland Mainz -- __ . . __ (o.\ \/ /.o) roland.ma...@nrubsig.org \__\/\/__/ MPEG specialist, C&&JAVA&&Sun&&Unix programmer /O /==\ O\ TEL +49 641 3992797 (;O/ \/ \O;) -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation:https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
Re: Switching groups with newgrp - how to get the new group with |GetTokenInformation()| ?
On Feb 22 18:38, Roland Mainz via Cygwin wrote: > Hi! > > > > If I switch the current user's group with /usr/bin/newgrp, how can a > (native) Win32 process use > |GetTokenInformation(GetCurrentThreadToken(), ...)| to find out which > group is the new "current group" (e.g. which |TokenInformationClass| > should I use) ? PSID sidbuf = (PSID) alloca (SECURITY_MAX_SID_SIZE); NTSTATUS status; ULONG size; status = NtQueryInformationToken (hProcToken, TokenPrimaryGroup, sidbuf, SECURITY_MAX_SID_SIZE, &size); Corinna -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation:https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
Creating a desktop shortcut to Cygwin emacs
Every three years or so I have to set up a new laptop, and several things that I only do in that period I either lose the notes on it, or something has changed that I'm not aware of. I'm installing Cygwin on a new laptop, version 3.5.0-1.x86_64. I had 3.4.6 on the old laptop. My desktop shortcut on the old laptop goes to: C:\cygwin64\bin\run2.exe --display 127.0.0.1:0.0 /usr/local/bin/emacs.xml I tried to set this up on the new laptop, and I noticed that "run2" doesn't exist, but "run" does. I tried just changing the command line to call "run" instead, but that resulting command line doesn't appear to do anything. No errors, just returns to the prompt and nothing happens. I tried googling for this, and I found a page on the EmacsWiki, but I can't tell if that is up to date. -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation:https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
Re: Creating a desktop shortcut to Cygwin emacs
On 2/22/2024 2:44 PM, David Karr via Cygwin wrote: Every three years or so I have to set up a new laptop, and several things that I only do in that period I either lose the notes on it, or something has changed that I'm not aware of. I'm installing Cygwin on a new laptop, version 3.5.0-1.x86_64. I had 3.4.6 on the old laptop. My desktop shortcut on the old laptop goes to: C:\cygwin64\bin\run2.exe --display 127.0.0.1:0.0 /usr/local/bin/emacs.xml I tried to set this up on the new laptop, and I noticed that "run2" doesn't exist, but "run" does. The run2 package still exists: https://cygwin.com/packages/summary/run2.html Ken -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation:https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
Re: Creating a desktop shortcut to Cygwin emacs
Ok. I forgot I had to add that package. However, now there's another odd problem. The command line still doesn't start anything, but it does print an error message, saying that it can't find "/usr/local/bin/emacs.xml". I can copy that file from the old laptop, but is that file supposed to be generated by something? On Thu, Feb 22, 2024 at 1:12 PM Ken Brown wrote: > On 2/22/2024 2:44 PM, David Karr via Cygwin wrote: > > Every three years or so I have to set up a new laptop, and several things > > that I only do in that period I either lose the notes on it, or something > > has changed that I'm not aware of. > > > > I'm installing Cygwin on a new laptop, version 3.5.0-1.x86_64. I had > 3.4.6 > > on the old laptop. > > > > My desktop shortcut on the old laptop goes to: > > > > C:\cygwin64\bin\run2.exe --display 127.0.0.1:0.0 > /usr/local/bin/emacs.xml > > > > I tried to set this up on the new laptop, and I noticed that "run2" > doesn't > > exist, but "run" does. > > The run2 package still exists: > >https://cygwin.com/packages/summary/run2.html > > Ken > -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation:https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
Re: Creating a desktop shortcut to Cygwin emacs
[Please don't top post on this list. Thanks.] On 2/22/2024 4:23 PM, David Karr wrote: Ok. I forgot I had to add that package. However, now there's another odd problem. The command line still doesn't start anything, but it does print an error message, saying that it can't find "/usr/local/bin/emacs.xml". I can copy that file from the old laptop, but is that file supposed to be generated by something? It's not generated automatically. There's a script /usr/bin/make-emacs-shortcut that you can run to create it. See /usr/share/doc/emacs/README.Cygwin for details. Or just copy it from your old computer. Ken -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation:https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
Re: Creating a desktop shortcut to Cygwin emacs
David Karr via Cygwin writes: > Ok. I forgot I had to add that package. > > However, now there's another odd problem. The command line still doesn't > start anything, but it does print an error message, saying that it can't > find "/usr/local/bin/emacs.xml". I can copy that file from the old laptop, > but is that file supposed to be generated by something? Don't remember, but here's my version, you should remove the 'x' Use something like this as your target for an XEmacs shortcut target \C64\bin\run2.exe /usr/local/bin/cygxemacs.xml And the following in cygxemacs.xml http://www.w3.org/2001/XMLSchema-instance"; xsi:noNamespaceSchemaLocation="run2.xsd"> -l -c /usr/local/bin/xemacs-21.5-b35 ht -- Henry S. Thompson, School of Informatics, University of Edinburgh 10 Crichton Street, Edinburgh EH8 9AB, SCOTLAND e-mail: h...@inf.ed.ac.uk URL: https://www.ltg.ed.ac.uk/~ht/ [mail from me _always_ has a .sig like this -- mail without it is forged spam] -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation:https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
Another possible python3.9 regression, mercurial spins but never wins?
TL;DR: After recent update to 3.9.18-2 I couldn't pull, running on Windows 10, latest cygwin1.dll. Reverting to 3.9.16-1 the problem goes away. >: hg --debug pull pulling from https://markup.co.uk/hg/xemacs using https://markup.co.uk/hg/xemacs sending capabilities command markup.co.uk certificate matched fingerprint [redacted] query 1; heads sending batch command searching for changes all local changesets known remotely sending getbundle command bundle2-input-bundle: with-transaction bundle2-input-part: "changegroup" (params: 1 mandatory 1 advisory) supported adding changesets add changeset f3ab63e5c39f [stuck, hard to kill, manager shows 10--20% CPU] Server python/mercurial installation hasn't changed. Server logs show no errors, finishing with a getbundle request that has completed successfully. Is this related to other already-signalled problems? ht -- Henry S. Thompson, School of Informatics, University of Edinburgh 10 Crichton Street, Edinburgh EH8 9AB, SCOTLAND e-mail: h...@inf.ed.ac.uk URL: https://www.ltg.ed.ac.uk/~ht/ [mail from me _always_ has a .sig like this -- mail without it is forged spam] -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation:https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
Re: Creating a desktop shortcut to Cygwin emacs
On 2024-02-22 12:44, David Karr via Cygwin wrote: Every three years or so I have to set up a new laptop, and several things that I only do in that period I either lose the notes on it, or something has changed that I'm not aware of. I'm installing Cygwin on a new laptop, version 3.5.0-1.x86_64. I had 3.4.6 on the old laptop. My desktop shortcut on the old laptop goes to: C:\cygwin64\bin\run2.exe --display 127.0.0.1:0.0 /usr/local/bin/emacs.xml I tried to set this up on the new laptop, and I noticed that "run2" doesn't exist, but "run" does. I tried just changing the command line to call "run" instead, but that resulting command line doesn't appear to do anything. No errors, just returns to the prompt and nothing happens. Different program with different requirements - run is part of Base cygwin, installed by default, not a lot else is except for install requirements, {core,cyg,diff,find,ipc-}utils, util-linux, and ex/vi. Package run2 has to be selected in Cygwin Setup, as does xinit to install the X server and run Cygwin GUI programs. I tried googling for this, and I found a page on the EmacsWiki, but I can't tell if that is up to date. -- Take care. Thanks, Brian Inglis Calgary, Alberta, Canada La perfection est atteinte Perfection is achieved non pas lorsqu'il n'y a plus rien à ajouter not when there is no more to add mais lorsqu'il n'y a plus rien à retirer but when there is no more to cut -- Antoine de Saint-Exupéry -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation:https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple