<div dir="auto">Unul din teste verifică ce se întâmplă când deschizi un fișier preexistent de lungime diferită de 0 cu modul "w" sau "w+". În ambele cazuri, fișierul trebuie să fie redus la dimensiunea 0.</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Mar 20, 2019, 13:50 Aida-Ștefania MANOLE (87667) via so <<a href="mailto:so@cursuri.cs.pub.ro">so@cursuri.cs.pub.ro</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">
<div id="m_-3608207308238173527divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif" dir="ltr">
<p style="margin-top:0;margin-bottom:0">Buna,</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0">Am o problema la primul test, cel cu fopen. Se creeaza un fisier care nu exista inainte, se inchide fara erori, insa cand este apelata in main file_size aparent caulculeaza o dimensiune diferita de 0. Am dezactivat optiunea
de cleanup pentru a vedea fisierul de referinta si acesta are dimesiunea 0 (am rulat stat pe el). Cum as putea sa rezolv aceasta problema? Nu-mi dau seama exact de unde vine. Am atasat si 2 imagini cu output-ul comenzii stat si rezultatul testului 1.</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0">Multumesc,</p>
<p style="margin-top:0;margin-bottom:0">Manole Aida Stefania</p>
<p style="margin-top:0;margin-bottom:0"><span style="font-size:12pt">Git repo: <a href="https://gitlab.cs.pub.ro/aida.manole/l3-so-assignments/tree/master/2-stdio" class="m_-3608207308238173527OWAAutoLink" id="m_-3608207308238173527LPlnk113823" target="_blank" rel="noreferrer">https://gitlab.cs.pub.ro/aida.manole/l3-so-assignments/tree/master/2-stdio</a></span></p>
<div id="m_-3608207308238173527LPBorder_GT_15529942183760.9133433917631315" style="margin-bottom:20px;overflow:auto;width:100%;text-indent:0px">
<table id="m_-3608207308238173527LPContainer_15529942183700.8658691191307484" cellspacing="0" style="width:90%;background-color:rgb(255,255,255);overflow:auto;padding-top:20px;padding-bottom:20px;margin-top:20px;border-top:1px dotted rgb(200,200,200);border-bottom:1px dotted rgb(200,200,200)">
<tbody>
<tr valign="top" style="border-spacing:0px">
<td id="m_-3608207308238173527ImageCell_15529942183720.5752061228295944" colspan="1" style="width:250px;display:table-cell;padding-right:20px">
<div id="m_-3608207308238173527LPImageContainer_15529942183720.42096296176122916" style="background-color:rgb(255,255,255);height:128px;margin:auto;display:table;width:128px">
<a id="m_-3608207308238173527LPImageAnchor_15529942183720.481925800566793" href="https://gitlab.cs.pub.ro/aida.manole/l3-so-assignments/tree/master/2-stdio" style="display:table-cell;text-align:center" target="_blank" rel="noreferrer"><img id="m_-3608207308238173527LPThumbnailImageID_15529942183720.6764095254994673" width="128" height="128" style="display:inline-block;max-width:250px;max-height:250px;height:128px;width:128px;border-width:0px;vertical-align:bottom" src="https://gitlab.cs.pub.ro/assets/gitlab_logo-7ae504fe4f68fdebb3c2034e36621930cd36ea87924c11ff65dbcb8ed50dca58.png"></a></div>
</td>
<td id="m_-3608207308238173527TextCell_15529942183730.10803129384231713" colspan="2" style="vertical-align:top;padding:0px;display:table-cell">
<div id="m_-3608207308238173527LPRemovePreviewContainer_15529942183730.1848749832779517"></div>
<div id="m_-3608207308238173527LPTitle_15529942183730.95597086920694" style="color:rgb(0,120,215);font-weight:400;font-size:21px;font-family:wf_segoe-ui_light,"Segoe UI Light","Segoe WP Light","Segoe UI","Segoe WP",Tahoma,Arial,sans-serif;line-height:21px">
<a id="m_-3608207308238173527LPUrlAnchor_15529942183740.04204508841774346" href="https://gitlab.cs.pub.ro/aida.manole/l3-so-assignments/tree/master/2-stdio" style="text-decoration:none" target="_blank" rel="noreferrer">Sign in</a></div>
<div id="m_-3608207308238173527LPMetadata_15529942183740.24595282450450595" style="margin:10px 0px 16px;color:rgb(102,102,102);font-weight:400;font-family:wf_segoe-ui_normal,"Segoe UI","Segoe WP",Tahoma,Arial,sans-serif;font-size:14px;line-height:14px">
<a href="http://gitlab.cs.pub.ro" target="_blank" rel="noreferrer">gitlab.cs.pub.ro</a></div>
<div id="m_-3608207308238173527LPDescription_15529942183750.8741882817138222" style="display:block;color:rgb(102,102,102);font-weight:400;font-family:wf_segoe-ui_normal,"Segoe UI","Segoe WP",Tahoma,Arial,sans-serif;font-size:14px;line-height:20px;max-height:100px;overflow:hidden">
GitLab Community Edition</div>
</td>
</tr>
</tbody>
</table>
</div>
<br>
<p></p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0"><a href="https://imgur.com/a/tZLzqA8" class="m_-3608207308238173527OWAAutoLink" id="m_-3608207308238173527LPlnk159815" target="_blank" rel="noreferrer">https://imgur.com/a/tZLzqA8</a><br>
</p>
<p style="margin-top:0;margin-bottom:0"><a href="https://imgur.com/a/oxyIjiJ" class="m_-3608207308238173527OWAAutoLink" id="m_-3608207308238173527LPlnk983532" target="_blank" rel="noreferrer">https://imgur.com/a/oxyIjiJ</a></p>
<div id="m_-3608207308238173527LPBorder_GT_15529941017320.5057640315886867" style="margin-bottom:20px;overflow:auto;width:100%;text-indent:0px">
<table id="m_-3608207308238173527LPContainer_15529941017170.32418565547011036" cellspacing="0" style="width:90%;background-color:rgb(255,255,255);overflow:auto;padding-top:20px;padding-bottom:20px;margin-top:20px;border-top:1px dotted rgb(200,200,200);border-bottom:1px dotted rgb(200,200,200)">
<tbody>
<tr valign="top" style="border-spacing:0px">
<td id="m_-3608207308238173527ImageCell_15529941017210.28505706496666927" colspan="1" style="width:250px;display:table-cell;padding-right:20px">
<div id="m_-3608207308238173527LPImageContainer_15529941017210.3766148327698049" style="background-color:rgb(255,255,255);height:131px;margin:auto;display:table;width:250px">
<a id="m_-3608207308238173527LPImageAnchor_15529941017230.9270055132406465" href="https://imgur.com/a/oxyIjiJ" style="display:table-cell;text-align:center" target="_blank" rel="noreferrer"><img id="m_-3608207308238173527LPThumbnailImageID_15529941017230.6416984996711954" style="display:inline-block;max-width:250px;max-height:250px;height:131px;width:250px;border-width:0px;vertical-align:bottom" width="250" height="131" src="https://i.imgur.com/Ui9xgS3.jpg?fb"></a></div>
</td>
<td id="m_-3608207308238173527TextCell_15529941017250.5207053656349585" colspan="2" style="vertical-align:top;padding:0px;display:table-cell">
<div id="m_-3608207308238173527LPRemovePreviewContainer_15529941017250.1066392422541178"></div>
<div id="m_-3608207308238173527LPTitle_15529941017250.4059189655641178" style="color:rgb(0,120,215);font-weight:400;font-size:21px;font-family:wf_segoe-ui_light,"Segoe UI Light","Segoe WP Light","Segoe UI","Segoe WP",Tahoma,Arial,sans-serif;line-height:21px">
<a id="m_-3608207308238173527LPUrlAnchor_15529941017280.9742049044334578" href="https://imgur.com/a/oxyIjiJ" style="text-decoration:none" target="_blank" rel="noreferrer">Imgur</a></div>
<div id="m_-3608207308238173527LPMetadata_15529941017280.1561400515121829" style="margin:10px 0px 16px;color:rgb(102,102,102);font-weight:400;font-family:wf_segoe-ui_normal,"Segoe UI","Segoe WP",Tahoma,Arial,sans-serif;font-size:14px;line-height:14px">
<a href="http://imgur.com" target="_blank" rel="noreferrer">imgur.com</a></div>
<div id="m_-3608207308238173527LPDescription_15529941017300.8583689381855515" style="display:block;color:rgb(102,102,102);font-weight:400;font-family:wf_segoe-ui_normal,"Segoe UI","Segoe WP",Tahoma,Arial,sans-serif;font-size:14px;line-height:20px;max-height:100px;overflow:hidden">
Post with 0 views.</div>
</td>
</tr>
</tbody>
</table>
</div>
<br>
<br>
<p></p>
</div>
</div>
_______________________________________________<br>
<a href="http://ocw.cs.pub.ro/courses/so/info/lista-discutii" rel="noreferrer noreferrer" target="_blank">http://ocw.cs.pub.ro/courses/so/info/lista-discutii</a></blockquote></div>