討論串[問題] free記憶體後的問題
共 2 篇文章
首頁
上一頁
1
下一頁
尾頁

推噓2(2推 0噓 1→)留言3則,0人參與, 最新作者littleshan (我要加入劍道社!)時間13年前 (2012/09/25 13:42), 編輯資訊
0
0
0
內容預覽:
哪本書寫的?. 依照 C99 標準 7.20.3.4p2. The realloc function deallocates the old object pointed to by ptr and. returns a pointer to a new object that has the si
(還有206個字)

推噓2(2推 0噓 6→)留言8則,0人參與, 最新作者ForWin (就是要贏)時間13年前 (2012/09/25 13:07), 編輯資訊
0
0
1
內容預覽:
問題(Question):. 小弟原本的想法是. malloc了一個arr1陣列. 之後realloc了一個arr2陣列. arr2的size是arr1的兩倍. 然後把arr1給free. 預期的正確結果(Expected Output):. 小弟預期free(arr1)之後,arr1和arr2因為
(還有152個字)
首頁
上一頁
1
下一頁
尾頁