diff --git a/src/hb-common.cc b/src/hb-common.cc index 7c6d26290..666d77daa 100644 --- a/src/hb-common.cc +++ b/src/hb-common.cc @@ -187,7 +187,7 @@ struct hb_language_item_t { return *this; } - void finish (void) { free (lang); } + void finish (void) { free ((void *) lang); } }; diff --git a/src/hb-common.h b/src/hb-common.h index 9079b2c04..40c188729 100644 --- a/src/hb-common.h +++ b/src/hb-common.h @@ -131,7 +131,7 @@ hb_direction_to_string (hb_direction_t direction); /* hb_language_t */ -typedef struct hb_language_impl_t *hb_language_t; +typedef const struct hb_language_impl_t *hb_language_t; /* len=-1 means str is NUL-terminated */ hb_language_t