[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] Hvad går der galt?



Egon Petersen wrote:
> Den melder en warning i linien "res=sorterA(navn[10][81]);", noget med
> warning: passing arg 1 of 'sorterA' makes pointer from integer without
> cast.

>   char navn[10][81];

Deklarere navn som værende et array af 10 arrays med 81 tegn i.

>   res = sorterA(navn[10][81]);

navn[10][81] er her det 81 tegn i den 10. streng. Dvs. du
overfører et tegn (uden for det allokerede array), mens
funktionen forventer et 2D array af tegn.

Det du mener er
res = sorterA(navn);


-- 
          Mvh. Carsten Svaneborg
       http://www.softwarepatenter.dk
 hvor fremtidens idemonopoler bekæmpes idag.


 
Home   Subscribe   Mail Archive   Index   Calendar   Search

 
 
Questions about the web-pages to <www_admin>. Last modified 2005-08-10, 20:10 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] *