<P><FONT face="Courier New">Xairetw!</FONT></P>
<P><FONT face="Courier New">Prospa8w na grapsw ena (to prwto mou)&nbsp;programma pou exei na kanei me</FONT></P>
<P><FONT face="Courier New">images. </FONT><FONT face="Courier New">Exw loipon mia synarthsh pou pairnei enan pointer se 2d</FONT></P>
<P><FONT face="Courier New">array (to image) </FONT><FONT face="Courier New">kai to epeksergazetai. Mesa s'ayth thn synarthsh kanw</FONT></P>
<P><FONT face="Courier New">malloc gia enan temp 2d array </FONT><FONT face="Courier New">wste na ginei olh h epksergasia s'ayton kai</FONT></P>
<P><FONT face="Courier New">prin epistrepsw ap'thn synarthsh na ton </FONT><FONT face="Courier New">kanw copy sto actual image (ksexasa</FONT></P>
<P><FONT face="Courier New">na pw oti einai char arrays):</FONT></P>
<P><FONT face="Courier New">void process(int size, char **image) {</FONT></P>
<P><FONT face="Courier New">&nbsp; int arraySize = 2*size+1; //arraySize = to mhkos ths pleyras&nbsp;toy#</FONT></P>
<P><FONT face="Courier New">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // TETRAGWNOU array</FONT></P>
<P><FONT face="Courier New">&nbsp; char **tmp = malloc(arraySize*sizeof(char *));</FONT></P>
<P><FONT face="Courier New">&nbsp; for (l;l&lt;arraySize;l++) {</FONT></P>
<P><FONT face="Courier New">&nbsp;&nbsp;&nbsp; tmp[i] = malloc(arraySize*sizeof(char))</FONT></P>
<P><FONT face="Courier New">&nbsp; }</FONT></P>
<P><FONT face="Courier New">&nbsp; // edw ginetai to processing ston tmp</FONT></P>
<P><FONT face="Courier New">&nbsp;&nbsp;// kai twra 8a ton kanw copy ston image</FONT></P>
<P><FONT face="Courier New">&nbsp;&nbsp;// kai 8a eley8erwsw th mnhmh</FONT></P>
<P><FONT face="Courier New">memmove (image, tmp, arraySize);</FONT></P>
<P><FONT face="Courier New">free(tmp);</FONT></P>
<P><FONT face="Courier New">}</FONT></P>
<P><FONT face="Courier New">Parolo pou kanei&nbsp;compile&nbsp;to programma me petaei Segm. Fault</FONT></P>
<P><FONT face="Courier New">otan to trexw, ti exw kanei la8os???</FONT></P>
<P><FONT face="Courier New">TIA</FONT></P>
<P><FONT face="Courier New">Giannhs</FONT></P><p><br><hr size=1><b>Do You Yahoo!?</b><br>Αποκτήστε την δωρεάν σας
@yahoo.gr διεύθυνση  στο 
<a href="http://www.otenet.gr/">Yahoo! Mail</a>.<br>