捕获文件似乎在数据包中间被截短了 - 如何防止此错误? [英] The capture file appears to have been cut short in the middle of a packet - how to prevent this error?
问题描述
在我的应用程序中,我打开 Tshark 进程并开始捕获,当我想完成捕获时,我杀死了 Tshark 进程,因此有时捕获文件已损坏,当我尝试打开此文件时,我收到错误 捕获文件似乎在数据包中间被截短了 - 如何防止此错误有没有一种方法可以关闭 Tshark 进程以避免此错误?
in my application i am open Tshark process and start capturing, when i want to finish to capturing i am kill the Tshark process so sometimes the capture file is corrupted and when i am trying to open this file i received the error the capture file appears to have been cut short in the middle of a packet - how to prevent this error there is a batter way to close the Tshark process to avoid this error ?
推荐答案
尝试使用 ctrl+c 停止捕获进程而不是终止进程.
Try stopping the capture process with ctrl+c instead of killing the process.
此外,您可以尝试使用 pcapfix 来修复损坏的数据包,它可能有助于使您现有的文件可读再次.
Also, you can try using pcapfix to fix your corrupted packets, it may help making your existing files readable again.
这篇关于捕获文件似乎在数据包中间被截短了 - 如何防止此错误?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!