diff --git a/compiler/2014/C_CodeGen.jrag b/compiler/2014/C_CodeGen.jrag index 81731a5afb935b9d3b45448ef35b3f8f578a0fe2..a68fa0ed46e50f9932a7ca3ab1176644919e2762 100644 --- a/compiler/2014/C_CodeGen.jrag +++ b/compiler/2014/C_CodeGen.jrag @@ -1038,7 +1038,7 @@ aspect C_Encoder { env.prefix + getName() + ", (labcomm2014_encoder_function)encode_" + env.prefix + getName() + - (!isVoid()?", v":", labcomm_void_instance")+");"); + (!isVoid()?", v":", labcomm2014_void_instance")+");"); env.unindent(); env.println("}"); } diff --git a/lib/c/2014/labcomm2014.c b/lib/c/2014/labcomm2014.c index f599e78e81b6076823d75c4bad84899540842bbf..5ce088ce9590a56f0defad6ce322213625025b4e 100644 --- a/lib/c/2014/labcomm2014.c +++ b/lib/c/2014/labcomm2014.c @@ -40,7 +40,7 @@ /* * A non-null void sample instance */ -void *labcomm_void_instance = &labcomm_void_instance; +void *labcomm2014_void_instance = &labcomm2014_void_instance; /* Unwrapping reader/writer functions */ @@ -162,7 +162,7 @@ const char *labcomm2014_error_get_str(enum labcomm2014_error error_id) return error_str; } -void labcomm20142014_on_error_fprintf(enum labcomm2014_error error_id, size_t nbr_va_args, ...) +void labcomm2014_on_error_fprintf(enum labcomm2014_error error_id, size_t nbr_va_args, ...) { #ifndef LABCOMM_NO_STDIO const char *err_msg = labcomm2014_error_get_str(error_id); // The final string to print. diff --git a/lib/c/2014/labcomm2014.h b/lib/c/2014/labcomm2014.h index ca490ccb6a0b375fd0cdcfac3b6c6215a24b5488..a4aa2f560188428c964b459dc7b4562c59893bc1 100644 --- a/lib/c/2014/labcomm2014.h +++ b/lib/c/2014/labcomm2014.h @@ -61,7 +61,7 @@ typedef void (*labcomm2014_error_handler_callback)(enum labcomm2014_error error_ /* Default error handler, prints message to stderr. * Extra info about the error can be supplied as char* as VA-args. Especially user defined errors should supply a describing string. if nbr_va_args > 1 the first variable argument must be a printf format string and the possibly following arguments are passed as va_args to vprintf. */ -void labcomm20142014_on_error_fprintf(enum labcomm2014_error error_id, size_t nbr_va_args, ...); +void labcomm2014_on_error_fprintf(enum labcomm2014_error error_id, size_t nbr_va_args, ...); /* Register a callback for the error handler for this encoder. */ void labcomm2014_register_error_handler_encoder(struct labcomm2014_encoder *encoder, labcomm2014_error_handler_callback callback); diff --git a/lib/c/2014/labcomm2014_decoder.c b/lib/c/2014/labcomm2014_decoder.c index a4cae4d66527674e526cf12f18e1d606c5161f4b..102d0da07e7bfe0dea7a640e2812570bec42e752 100644 --- a/lib/c/2014/labcomm2014_decoder.c +++ b/lib/c/2014/labcomm2014_decoder.c @@ -703,7 +703,7 @@ struct labcomm2014_decoder *labcomm2014_decoder_new( result->decoder.error = error; result->decoder.memory = memory; result->decoder.scheduler = scheduler; - result->decoder.on_error = labcomm20142014_on_error_fprintf; + result->decoder.on_error = labcomm2014_on_error_fprintf; result->decoder.free = do_free; result->decoder.decode_one = do_decode_one; result->decoder.ref_register = do_ref_register; diff --git a/lib/c/2014/labcomm2014_private.h b/lib/c/2014/labcomm2014_private.h index 964299b146ed04dd69e27ab2c1cb683476a7917c..b70c44b6f015b3f9e0e5b4db8c91bc37522710d4 100644 --- a/lib/c/2014/labcomm2014_private.h +++ b/lib/c/2014/labcomm2014_private.h @@ -84,7 +84,7 @@ /* * A non-null void sample instance */ -extern void *labcomm_void_instance; +extern void *labcomm2014_void_instance; /* * Semi private dynamic memory declarations @@ -320,7 +320,7 @@ static inline char *labcomm2014_read_string(struct labcomm2014_reader *r) length = labcomm2014_read_packed32(r); result = labcomm2014_memory_alloc(r->memory, 1, length + 1); if (!result) { - labcomm20142014_on_error_fprintf(LABCOMM2014_ERROR_MEMORY, 4, "%d byte at %s:%d", + labcomm2014_on_error_fprintf(LABCOMM2014_ERROR_MEMORY, 4, "%d byte at %s:%d", length+1, __FUNCTION__, __LINE__); return NULL; }