[Openvas-devel] [Openvas-commits] r7767 - in trunk/openvas-libraries: . omp

Matthew Mundell matthew.mundell at greenbone.net
Wed May 19 12:40:51 CEST 2010


> > > @@ -76,12 +76,12 @@
> > >   * @return A newly allocated entity.
> > >   */
> > >  entity_t
> > > -make_entity (const char* name, const char* text)
> > > +make_entity (const char *name, const char *text)
> >
> > It's weird how it has made this consistent...
> >
> > >  {
> > >    entity_t entity;
> > >    entity = g_malloc (sizeof (*entity));
> > > -  entity->name = g_strdup (name ?: "");
> > > -  entity->text = g_strdup (text ?: "");
> > > +  entity->name = g_strdup (name ? : "");
> > > +  entity->text = g_strdup (text ? : "");
> > >    entity->entities = NULL;
> > >    entity->attributes = NULL;
> > >    return entity;
> > > @@ -129,7 +129,7 @@
> > >   * @return The new entity.
> > >   */
> > >  entity_t
> > > -add_entity (entities_t* entities, const char* name, const char* text)
> > > +add_entity (entities_t * entities, const char *name, const char *text)
> >
> > ..but put a space after the first start here.
>
> Afaics, it normally does the (type * var)- style in arguments and the (type
> *var) one for va. Maybe anything const is a special case?

	@@ -314,22 +314,20 @@
	  * @param[in]  error             Error parameter.
	  */
	 void
	-handle_start_element (GMarkupParseContext* context,
	-                      const gchar *element_name,
	-                      const gchar **attribute_names,
	-                      const gchar **attribute_values,
	-                      gpointer user_data,
	-                      GError **error)
	+handle_start_element (GMarkupParseContext * context, const gchar * element_name,
	+                      const gchar ** attribute_names,
	+                      const gchar ** attribute_values, gpointer user_data,
	+                      GError ** error)
	 {

Here it has added the space for const arg element_name.  Maybe it's
arbitrary.


More information about the Openvas-devel mailing list