Citrix Virtual Channel SDK - How to return a string value from ICA client to server?

StackOverflow https://stackoverflow.com/questions/17652248

  •  03-06-2022
  •  | 
  •  

문제

I'm using XenDesktop 5.6 (server) and Citrix Receiver 3.6 (client). I've used the Virtual Channel SDK to create a channel between server and client and pass C-style structures back and forth, using the examples found here. I can easily pass simple numeric types (USHORT, etc.) between client and server just by setting the appropriate structure field (e.g. g_pMixHd->dwRetVal = 1) but I cannot do the same with string types (LPBYTES, PSZ, PUCHAR). I have tried allocating memory on client and/or server, updating the structure's length field and other approaches but nothing seems to work.

All I want to do is have my client assign a simple ANSI/ASCII string in the receiving structure and have it passed back to the server. Has anybody done this? Can you help?

올바른 솔루션이 없습니다

다른 팁

Without seeing more details, I'll gues that this is probably because you're using pointer-based strings.

Let's say you have a C structure that has a string member. That member should not be a string, rather it should be a byte array, and you should copy the string into the byte array before sending the packet.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top