paulscherrerinstitute / pcaspy

Portable Channel Access Server in Python
BSD 3-Clause "New" or "Revised" License
33 stars 24 forks source link

char array isn't initialized #14

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Run the example/pysh.py
2. Create an MEDM panel, with a text entry (with format set to "string") for PV 
"MTEST:COMMAND".
3. Execute.

What is the expected output? What do you see instead?
MEDM text entry widget should display empty string. But instead the following 
error is shown by MEDM,
medmUpdateChannelCb: Bad status [400] for T1:TEST-SYS_STR: No reasonable data 
conversion between client and server types

And on the server side, error is,
filename="../../../../src/cas/generic/casStrmClient.cc" line number=895
No conversion between src & dest types no conversion between event app type=16 
and DBR type=18 Element count=60

Original issue reported on code.google.com by xiaoqian...@gmail.com on 3 Mar 2015 at 7:41

GoogleCodeExporter commented 9 years ago
After investigation, the real problem is with empty strings. It causes invalid 
gdd value. The fix is to ensure the string is null terminated and thus 
resulting a valid gdd value. Commit 436aa63248415a2604356d754fbdd21ec8426af0

Original comment by xiaoqian...@gmail.com on 4 Mar 2015 at 10:05