rem: sprintf(temp,"%s Values are not implemented",
add: snprintf(temp,sizeof(temp),"%s Values are not implemented",
context: icalvalue* icalvalue_new_from_string_with_error(icalvalue_kind kind,const char* str,icalproperty** error){    struct icalvalue_impl *value = 0;    icalerror_check_arg_rz(str!=0,"str");    if (error != 0){	*error = 0;    }    switch (kind){    case ICAL_ATTACH_VALUE:         {        struct icalattachtype *attach = icalattachtype_new();      	value = icalvalue_new_attach( attach );        icalattachtype_free( attach );        icalattachtype_set_url( value->data.v_attach, str );				}        break;    case ICAL_BINARY_VALUE:    case ICAL_BOOLEAN_VALUE:        {            /* HACK */            value = 0;	    if (error != 0){		char temp[TMP_BUF_SIZE];		sprintf(temp,"%s Values are not implemented",                        icalparameter_kind_to_string(kind));		*error = icalproperty_vanew_xlicerror(                                   temp,                                   icalparameter_new_xlicerrortype(                                        ICAL_XLICERRORTYPE_VALUEPARSEERROR),                                   0);	    }	    break;	}    case ICAL_TRANSP_VALUE:        value = icalvalue_new_enum(kind, ICAL_TRANSP_X,str);        break;    case ICAL_METHOD_VALUE:        value = icalvalue_new_enum(kind, ICAL_METHOD_X,str);        break;    case ICAL_STATUS_VALUE:        value = icalvalue_new_enum(kind, ICAL_STATUS_X,str);        break;    case ICAL_ACTION_VALUE:        value = icalvalue_new_enum(kind, ICAL_ACTION_X,str);        break;    case ICAL_CLASS_VALUE:        value = icalvalue_new_enum(kind, ICAL_CLASS_X,str);        break;    case ICAL_INTEGER_VALUE:	{	    value = icalvalue_new_integer(atoi(str));	    break;	}    case ICAL_FLOAT_VALUE:        {	    value = icalvalue_new_float(atof(str));	    break;	}    case ICAL_UTCOFFSET_VALUE:	{	    value = icalparser_parse_value(kind,str,(icalcomponent*)0);	    break;	}    case ICAL_TEXT_VALUE:	{	    char* dequoted_str = icalmemory_strdup_and_dequote(str);	    value = icalvalue_new_text(dequoted_str);	    free(dequoted_str);	    break;	}    case ICAL_STRING_VALUE:	{	    value = icalvalue_new_string(str);	    break;	}    case ICAL_CALADDRESS_VALUE:	{	    value = icalvalue_new_caladdress(str);	    break;	}    case ICAL_URI_VALUE:	{	    value = icalvalue_new_uri(str);	    break;	}    case ICAL_GEO_VALUE:	{	    value = 0;	    /* HACK */	    if (error != 0){		char temp[TMP_BUF_SIZE];		sprintf(temp,"GEO Values are not implemented");		*error = icalproperty_vanew_xlicerror(                                                      temp,                                                      icalparameter_new_xlicerrortype(                                                                                      ICAL_XLICERRORTYPE_VALUEPARSEERROR),                                                      0);	    }	    /*icalerror_warn("Parsing GEO properties is unimplmeneted");*/	    break;	}    case ICAL_RECUR_VALUE:	{	    struct icalrecurrencetype rt;	    rt = icalrecurrencetype_from_string(str);            if(rt.freq != ICAL_NO_RECURRENCE){                value = icalvalue_new_recur(rt);            }	    break;	}    case ICAL_DATE_VALUE:    case ICAL_DATETIME_VALUE:	{	    struct icaltimetype tt;	    tt = icaltime_from_string(str);            if(!icaltime_is_null_time(tt)){                value = icalvalue_new_impl(kind);                value->data.v_time = tt;                icalvalue_reset_kind(value);            }	    break;	}    case ICAL_DATETIMEPERIOD_VALUE:	{	    struct icaltimetype tt;            struct icalperiodtype p;            tt = icaltime_from_string(str);            p = icalperiodtype_from_string(str);            if(!icaltime_is_null_time(tt)){                value = icalvalue_new_datetime(tt);            } else if (!icalperiodtype_is_null_period(p)){                value = icalvalue_new_period(p);            }            break;	}    case ICAL_DURATION_VALUE:	{            struct icaldurationtype dur = icaldurationtype_from_string(str);            if(icaldurationtype_is_null_duration(dur)){                value = 0;            } else {                value = icalvalue_new_duration(dur);            }	    break;	}    case ICAL_PERIOD_VALUE:	{            struct icalperiodtype p;            p = icalperiodtype_from_string(str);            if(!icalperiodtype_is_null_period(p)){                value = icalvalue_new_period(p);            }            break;	}    case ICAL_TRIGGER_VALUE:	{	    struct icaltriggertype tr = icaltriggertype_from_string(str);            if (!icaltriggertype_is_null_trigger(tr)){                value = icalvalue_new_trigger(tr);            }	    break;	}    case ICAL_REQUESTSTATUS_VALUE:        {            struct icalreqstattype rst = icalreqstattype_from_string(str);            if(rst.code != ICAL_UNKNOWN_STATUS){                value = icalvalue_new_requeststatus(rst);            }            break;        }    default:        {            if (error != 0 ){		char temp[TMP_BUF_SIZE];                snprintf(temp,TMP_BUF_SIZE,"Unknown type for \'%s\'",str);		*error = icalproperty_vanew_xlicerror(		    temp,		    icalparameter_new_xlicerrortype(			ICAL_XLICERRORTYPE_VALUEPARSEERROR),		    0);	    }	    icalerror_warn("icalvalue_new_from_string got an unknown value type");            value=0;	}    }    if (error != 0 && *error == 0 && value == 0){	char temp[TMP_BUF_SIZE];        snprintf(temp,TMP_BUF_SIZE,"Failed to parse value: \'%s\'",str);	*error = icalproperty_vanew_xlicerror(	    temp,	    icalparameter_new_xlicerrortype(		ICAL_XLICERRORTYPE_VALUEPARSEERROR),	    0);    }    return value;}