Mageia Bugzilla – Attachment 11567 Details for
Bug 26291
VBoxClient segfaults every 5 seconds
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
New Account
|
Forgot Password
[patch]
Patch
VirtualBox-6.1.4-vboxclient-fix.patch (text/plain), 1.93 KB, created by
Giuseppe Ghibò
on 2020-03-29 22:11:49 CEST
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Giuseppe Ghibò
Created:
2020-03-29 22:11:49 CEST
Size:
1.93 KB
patch
obsolete
>--- a/src/VBox/Additions/x11/VBoxClient/clipboard.cpp >+++ b/src/VBox/Additions/x11/VBoxClient/clipboard.cpp >@@ -107,7 +107,7 @@ > else > #endif > { >- uint32_t cbData = _4K; /** @ŧodo Make this dynamic. */ >+ uint32_t cbData = _4K; /** @todo Make this dynamic. */ > void *pvData = RTMemAlloc(cbData); > if (pvData) > { >@@ -215,7 +215,6 @@ > * > * @returns VBox status code. > */ >-#if 0 > static int vboxClipboardConnect(void) > { > LogFlowFuncEnter(); >@@ -245,7 +244,6 @@ > LogFlowFuncLeaveRC(rc); > return rc; > } >-#endif > > /** > * The main loop of our clipboard reader. >@@ -469,7 +467,7 @@ > RT_NOREF(ppInterface, fDaemonised); > > /* Initialise the guest library. */ >- int rc = 0; //vboxClipboardConnect(); >+ int rc = vboxClipboardConnect(); > if (RT_SUCCESS(rc)) > { > #ifdef VBOX_WITH_SHARED_CLIPBOARD_FUSE >@@ -477,10 +475,8 @@ > if (RT_SUCCESS(rc)) > { > #endif >- RTThreadSleep(60 * 1000); >+ rc = vboxClipboardMain(); > >- //rc = vboxClipboardMain(); >- > #ifdef VBOX_WITH_SHARED_CLIPBOARD_FUSE > int rc2 = vboxClipboardFUSEStop(); > if (RT_SUCCESS(rc)) >--- a/src/VBox/Additions/x11/VBoxClient/display-svga-x11.cpp >+++ b/src/VBox/Additions/x11/VBoxClient/display-svga-x11.cpp >@@ -100,16 +100,19 @@ static void x11Connect(struct X11CONTEXT > { > XCloseDisplay(pContext->pDisplay); > pContext->pDisplay = NULL; >+ return; > } > if (!XRRQueryExtension(pContext->pDisplay, &pContext->hRandREventBase, &pContext->hRandRErrorBase)) > { > XCloseDisplay(pContext->pDisplay); > pContext->pDisplay = NULL; >+ return; > } > if (!XRRQueryVersion(pContext->pDisplay, &pContext->hRandRMajor, &pContext->hRandRMinor)) > { > XCloseDisplay(pContext->pDisplay); > pContext->pDisplay = NULL; >+ return; > } > pContext->rootWindow = DefaultRootWindow(pContext->pDisplay); > }
--- a/src/VBox/Additions/x11/VBoxClient/clipboard.cpp +++ b/src/VBox/Additions/x11/VBoxClient/clipboard.cpp @@ -107,7 +107,7 @@ else #endif { - uint32_t cbData = _4K; /** @ŧodo Make this dynamic. */ + uint32_t cbData = _4K; /** @todo Make this dynamic. */ void *pvData = RTMemAlloc(cbData); if (pvData) { @@ -215,7 +215,6 @@ * * @returns VBox status code. */ -#if 0 static int vboxClipboardConnect(void) { LogFlowFuncEnter(); @@ -245,7 +244,6 @@ LogFlowFuncLeaveRC(rc); return rc; } -#endif /** * The main loop of our clipboard reader. @@ -469,7 +467,7 @@ RT_NOREF(ppInterface, fDaemonised); /* Initialise the guest library. */ - int rc = 0; //vboxClipboardConnect(); + int rc = vboxClipboardConnect(); if (RT_SUCCESS(rc)) { #ifdef VBOX_WITH_SHARED_CLIPBOARD_FUSE @@ -477,10 +475,8 @@ if (RT_SUCCESS(rc)) { #endif - RTThreadSleep(60 * 1000); + rc = vboxClipboardMain(); - //rc = vboxClipboardMain(); - #ifdef VBOX_WITH_SHARED_CLIPBOARD_FUSE int rc2 = vboxClipboardFUSEStop(); if (RT_SUCCESS(rc)) --- a/src/VBox/Additions/x11/VBoxClient/display-svga-x11.cpp +++ b/src/VBox/Additions/x11/VBoxClient/display-svga-x11.cpp @@ -100,16 +100,19 @@ static void x11Connect(struct X11CONTEXT { XCloseDisplay(pContext->pDisplay); pContext->pDisplay = NULL; + return; } if (!XRRQueryExtension(pContext->pDisplay, &pContext->hRandREventBase, &pContext->hRandRErrorBase)) { XCloseDisplay(pContext->pDisplay); pContext->pDisplay = NULL; + return; } if (!XRRQueryVersion(pContext->pDisplay, &pContext->hRandRMajor, &pContext->hRandRMinor)) { XCloseDisplay(pContext->pDisplay); pContext->pDisplay = NULL; + return; } pContext->rootWindow = DefaultRootWindow(pContext->pDisplay); }
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 26291
:
11534
| 11567