We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
JDK版本: openjdk_20 hutool版本: 5.8.23(请确保最新尝试是否还有问题)
doc文件错误被认为是xls文件
byte[] bytes = StreamUtils.copyToByteArray(fileData.getInputStream()); String mimeType = FileMagicNumber.getMagicNumber(bytes).getMimeType();
堆栈信息 无
测试涉及到的文件(注意脱密)
由于文件涉密暂不能提供,但已确认是doc文件且被word打开
The text was updated successfully, but these errors were encountered:
如果文件经过WPS编辑,会导致magic number错误。
考虑扩展名辅助识别。
Sorry, something went wrong.
No branches or pull requests
版本情况
JDK版本: openjdk_20
hutool版本: 5.8.23(请确保最新尝试是否还有问题)
问题描述(包括截图)
doc文件错误被认为是xls文件
堆栈信息
无
测试涉及到的文件(注意脱密)
由于文件涉密暂不能提供,但已确认是doc文件且被word打开
The text was updated successfully, but these errors were encountered: