Commit 36685b07 authored by Damjan Jovanovic's avatar Damjan Jovanovic Committed by Alexandre Julliard

winex11.drv: Fix file drops on KDE4 and XFCE.

parent 1591e3a7
...@@ -375,9 +375,7 @@ static int X11DRV_XDND_DeconstructTextURIList(int property, void* data, int len) ...@@ -375,9 +375,7 @@ static int X11DRV_XDND_DeconstructTextURIList(int property, void* data, int len)
{ {
while (end < len && uriList[end] != '\r') while (end < len && uriList[end] != '\r')
++end; ++end;
if (end == len) if (end < (len - 1) && uriList[end+1] != '\n')
break;
if (uriList[end+1] != '\n')
{ {
WARN("URI list line doesn't end in \\r\\n\n"); WARN("URI list line doesn't end in \\r\\n\n");
break; break;
...@@ -412,7 +410,7 @@ static int X11DRV_XDND_DeconstructTextURIList(int property, void* data, int len) ...@@ -412,7 +410,7 @@ static int X11DRV_XDND_DeconstructTextURIList(int property, void* data, int len)
start = end + 2; start = end + 2;
end = start; end = start;
} }
if (out && end == len) if (out && end >= len)
{ {
DROPFILES *dropFiles; DROPFILES *dropFiles;
dropFiles = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(DROPFILES) + size + 1); dropFiles = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(DROPFILES) + size + 1);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment