Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 765205 Details for
Bug 746227
net-misc/tigervnc-1.11.0-r2[server] different calling conventions for vncserver startup
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
tigervnc-1.12.0-vncsession.c.patch (text/plain), 1.72 KB, created by
Norman Back
on 2022-02-15 19:37:19 UTC
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Norman Back
Created:
2022-02-15 19:37:19 UTC
Size:
1.72 KB
patch
obsolete
>--- a/unix/vncserver/vncsession.c 2022-02-14 15:33:43.235664547 +0000 >+++ b/unix/vncserver/vncsession.c 2022-02-14 17:09:00.586000641 +0000 >@@ -413,7 +413,7 @@ > } > > static pid_t >-run_script(const char *username, const char *display, char **envp) >+run_script(const char *username, const char *display, const char *xsession, char **envp) > { > struct passwd *pwent; > pid_t pid; >@@ -472,8 +472,14 @@ > > child_argv[0] = CMAKE_INSTALL_FULL_LIBEXECDIR "/vncserver"; > child_argv[1] = display; >- child_argv[2] = NULL; >- >+ if ( strlen(xsession) > 0 ){ >+ child_argv[2] = xsession; >+ child_argv[3] = NULL; >+ } >+ else{ >+ child_argv[2] = NULL; >+ } >+ > execvp(child_argv[0], (char*const*)child_argv); > > // execvp failed >@@ -488,16 +494,19 @@ > char pid_file[PATH_MAX]; > FILE *f; > >- const char *username, *display; >+ const char *username, *display, *xsession=""; > >- if ((argc != 3) || (argv[2][0] != ':')) { >+ if ( ( (argc != 3) && (argc != 4) ) || (argv[2][0] != ':')) { > fprintf(stderr, "Syntax:\n"); >- fprintf(stderr, " %s <username> <display>\n", argv[0]); >+ fprintf(stderr, " %s <username> <display> [<xsession-file>]\n", argv[0]); > return EX_USAGE; > } > > username = argv[1]; > display = argv[2]; >+ if (argc == 4 ) { >+ xsession = argv[3]; >+ } > > if (geteuid() != 0) { > fprintf(stderr, "This program needs to be run as root!\n"); >@@ -546,8 +555,8 @@ > } > > setup_signals(); >- >- script = run_script(username, display, child_env); >+ >+ script = run_script(username, display, xsession, child_env); > if (script == -1) { > syslog(LOG_CRIT, "Failure starting vncserver script"); > stop_pam(pamh, pamret);
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 746227
:
663613
|
676600
|
676603
|
765203
|
765204
| 765205 |
765206
|
765207
|
765208