LibCSS: constify the css_stylesheet_params for css_stylesheet_create

James Montgomerie jamie at
Fri Sep 2 12:23:41 BST 2011


A small thing, so not worth a patch to the list: it strikes me that the params argument to css_stylesheet_create could be const (I noticed it wasn't when, as a client, making a const css_stylesheet_params to pass to it for use with inline styles).

Not a big deal, certainly, but would help clients using the compiler to ensure their code is clean.

i.e. change

css_error css_stylesheet_create(css_stylesheet_params *params,
		css_allocator_fn alloc, void *alloc_pw, 
		css_stylesheet **stylesheet)

css_error css_stylesheet_create(const css_stylesheet_params *params,
		css_allocator_fn alloc, void *alloc_pw, 
		css_stylesheet **stylesheet)

I've done this locally, and all seems to be well afterwards.


More information about the netsurf-dev mailing list