Commit 8e9d0172 authored by claes's avatar claes

cdh_SuppressSuper function

parent 056a75e1
...@@ -503,7 +503,7 @@ cdh_AttrValueToString ( ...@@ -503,7 +503,7 @@ cdh_AttrValueToString (
sprintf(sval, "%d", *(pwr_tInt8 *) Value); sprintf(sval, "%d", *(pwr_tInt8 *) Value);
break; break;
case pwr_eType_Int16: case pwr_eType_Int16:
sprintf(sval, "%d", *(pwr_tInt16 *) Value); sprintf(sval, "%hd", *(pwr_tInt16 *) Value);
break; break;
case pwr_eType_Int32: case pwr_eType_Int32:
sprintf(sval, "%d", *(pwr_tInt32 *) Value); sprintf(sval, "%d", *(pwr_tInt32 *) Value);
...@@ -512,7 +512,7 @@ cdh_AttrValueToString ( ...@@ -512,7 +512,7 @@ cdh_AttrValueToString (
sprintf(sval, "%u", *(pwr_tUInt8 *) Value); sprintf(sval, "%u", *(pwr_tUInt8 *) Value);
break; break;
case pwr_eType_UInt16: case pwr_eType_UInt16:
sprintf(sval, "%u", *(pwr_tUInt16 *) Value); sprintf(sval, "%hu", *(pwr_tUInt16 *) Value);
break; break;
case pwr_eType_UInt32: case pwr_eType_UInt32:
sprintf(sval, "%u", *(pwr_tUInt32 *) Value); sprintf(sval, "%u", *(pwr_tUInt32 *) Value);
...@@ -2532,6 +2532,13 @@ pwr_sAttrRef cdh_ArefAdd( pwr_sAttrRef *arp1, pwr_sAttrRef *arp2) ...@@ -2532,6 +2532,13 @@ pwr_sAttrRef cdh_ArefAdd( pwr_sAttrRef *arp1, pwr_sAttrRef *arp2)
return aref; return aref;
} }
void cdh_SuppressSuper( char *out, char *in)
{
char *s = in;
while ( strncmp( s, "Super.", 6) == 0)
s += 6;
strcpy( out, s);
}
/*@}*/ /*@}*/
......
...@@ -969,6 +969,8 @@ pwr_sAttrRef cdh_ArefToCastAref( pwr_sAttrRef *arp); ...@@ -969,6 +969,8 @@ pwr_sAttrRef cdh_ArefToCastAref( pwr_sAttrRef *arp);
pwr_sAttrRef cdh_ArefAdd( pwr_sAttrRef *arp1, pwr_sAttrRef *arp2); pwr_sAttrRef cdh_ArefAdd( pwr_sAttrRef *arp1, pwr_sAttrRef *arp2);
void cdh_SuppressSuper( char *out, char *in);
/*@}*/ /*@}*/
#ifdef __cplusplus #ifdef __cplusplus
......
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