[an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive]
 
[an error occurred while processing this directive] [an error occurred while processing this directive]
Skåne Sjælland Linux User Group - http://www.sslug.dk Home   Subscribe   Mail Archive   Forum   Calendar   Search
MhonArc Date: [Date Prev] [Date Index] [Date Next]   Thread: [Date Prev] [Thread Index] [Date Next]   MhonArc
 

Re: [CPROG] modulprogrammering



Det sidste komma er rigtigt nok. Da file_operations er en struct der ofte
bliver lavet om i.
Sætter man et komma bag det sidste element, så udfylder compileren resten.
Den pæne måde at gøre det på er nok følgende
struct file_operations fortune_fops{
    read:    fortune_read;
};

Hilsen Lars Hansen
Mads Bondo Dydensborg wrote:

> On Sun, 30 Jul 2000, lars wrote:
>
> >
> > //definerer vores filoperationer( indtil videre kun read )
> > static struct file_operations fortune_fops = {
> >  NULL, //lseek
> >  fortune_read,
> >  NULL, //write
> > };
>
> Jeg skulle mene at du har et komma for meget her.
>
> >
> > Jeg får den følgende fejl:
> >
> > fortune.c:26: warning: `struct file' declared inside parameter list
>
> Du har nok rod i nogen includes.
>
> Mads
>
> --
> Mads Bondo Dydensborg.                               sslug@sslug
> Any attempt to brew coffee with a teapot should result in the error
> code "418 I'm a teapot". The resulting entity body MAY be short and
> stout.
>                                  - rfc2324. Go look it up... :-)



 
Home   Subscribe   Mail Archive   Index   Calendar   Search

 
 
Questions about the web-pages to <www_admin>. Last modified 2005-08-10, 20:08 CEST [an error occurred while processing this directive]
This page is maintained by [an error occurred while processing this directive]MHonArc [an error occurred while processing this directive] # [an error occurred while processing this directive] *