Re: [gamin] FAMCancelMonitor - definition should contain const



On Wed, Nov 24, 2004 at 05:25:40PM +0100, Michael Tautschnig wrote:
> Hi all!
> 
> For consistency-reasons FAMCancelMonitor should IMHO be defined as
> extern int FAMCancelMonitor     (FAMConnection *fc,
>                                  const FAMRequest *fr);
> 
> , i.e., having a ,,const'' FAMRequest.

  the fam.h header from the original SGI distribution states:

int FAMCancelMonitor(FAMConnection *fc, const FAMRequest *fr);

and

 This routine will free the FAMRequest structure that is passed in.

So yes it seems you are right, but this just violates the API as described !
I note that libgamin does *not* free the structure passed because it did
break FAM compatibility .... And should not modify it either, so technically
speaking this is right.

Daniel

-- 
Daniel Veillard      | Red Hat Desktop team http://redhat.com/
veillard redhat com  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]