The fmemopen() function gives you a stdio FILE * object that refers to a buffer in memory. Replacing the open of test.jpg with a single call to fmemopen solves half the problem
fmemopen()函数提供了一个stdioFILE *对象,该对象表示内存中的一个缓冲区。
In most cases, if what you want can be done with a higher-level library (stdio instead of raw reads and writes, for instance), you should do that; it gives you more insulation from possible quirks.
在大部分情况中,如果您希望可以使用更高级的库(举例来说,使用stdio,而不是原始的读写操作),就应该这样做;这可以帮您更好地回避这些问题。
Starting with IDS v10, ontape operations can now be directed to or from "standard in" or "standard out" (STDIO), thereby providing support for a wider range of options.
从IDSv10开始,ontape操作可以被定向到标准输入或标准输出设备(“standardin”或“standardout”,STDIO),因此为很多选项提供了支持。
Starting with IDS v10, ontape operations can now be directed to or from "standard in" or "standard out" (STDIO), thereby providing support for a wider range of options.
从IDSv10开始,ontape操作可以被定向到标准输入或标准输出设备(“standardin”或“standardout”,STDIO),因此为很多选项提供了支持。
应用推荐