File descriptor detection method and equipment

A file descriptor and detection method technology, which is applied in the computer field and can solve problems such as file descriptor error closing, exception, and application program crash.

Pending Publication Date: 2022-03-15
BEIJING BYTEDANCE NETWORK TECH CO LTD
View PDF0 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

Since the file descriptor is globally accessible in the process, the dynamic link library that closes the file descriptor may be different from the dynamic link library that created the file descriptor, resulting in the problem that the file descriptor is closed incorrectly, causing the application Running crashes or abnormal problems

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • File descriptor detection method and equipment
  • File descriptor detection method and equipment
  • File descriptor detection method and equipment

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0024] In order to make the purpose, technical solutions and advantages of the embodiments of the present disclosure clearer, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments It is a part of the embodiments of the present disclosure, but not all of them. Based on the embodiments in the present disclosure, all other embodiments obtained by persons of ordinary skill in the art without creative efforts fall within the protection scope of the present disclosure.

[0025] see figure 1 , figure 1 Schematic diagram of the scene for file descriptor detection. Such as figure 1 As shown, during the startup or running of the application program 1, multiple dynamic link libraries (so) may be called. For example, the application program 1 needs to call the dynamic link library 1 and the dynamic link library...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The embodiment of the invention provides a file descriptor detection method and equipment, and the method comprises the steps: obtaining a to-be-closed file descriptor corresponding to a file descriptor closing operation and the information of closing a dynamic link library corresponding to the to-be-closed file descriptor when the file descriptor closing operation is detected, and determining information for creating the dynamic link library corresponding to the descriptor of the file to be closed. When it is determined that the information for closing the dynamic link library is not matched with the information for creating the dynamic link library, file descriptor wrong closing information is reported, and the file descriptors are closed, so that the file descriptors which are closed wrongly are automatically and accurately detected, and the file descriptor wrong closing information corresponding to the file descriptors which are closed wrongly is reported; therefore, related developers can debug the application program according to the detected file descriptor which is mistakenly closed, the risk that the application program crashes or is abnormal is reduced, and the user experience of the program is improved.

Description

technical field [0001] The embodiments of the present disclosure relate to the field of computer technology, and in particular, to a method and device for detecting a file descriptor. Background technique [0002] The file descriptor is an index created by the kernel to efficiently manage the opened files, and is used to point to the opened files. [0003] Currently, when an application is running, multiple dynamic link libraries may be loaded. In the process of loading the dynamic link library, when the dynamic link library opens the file, the kernel will create the file descriptor corresponding to the file, then the dynamic link library can be used as the dynamic link library for creating the file descriptor. When the dynamic link library closes the file, it closes the corresponding file descriptor. Since the file descriptor is globally accessible in the process, the dynamic link library that closes the file descriptor may be different from the dynamic link library that ...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): G06F9/445G06F11/36
CPCG06F9/4451G06F9/44521G06F11/362
Inventor 韩立
Owner BEIJING BYTEDANCE NETWORK TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products