回复:自动备份 wallet.dat
原始发布页
打开来源页面查看 1 个交叉存档
抱歉,我最近实在太忙,一直只是略读消息,但仍然跟不上。
我们希望尽可能避免调用 Windows API。它们通常需要大约 6 到 8 个参数,还需要大量测试才能正确使用,做一件简单的事就得写整整一页代码。
我通常会避开 iostreams。感觉我太经常碰到它的局限了。他们在 90 年代算是把 C++ 流标准搞砸了,这很可惜,因为流如果设计得当,可以非常强大和实用。在 rpc.cpp 中使用它最终可能仍会被证明是个错误。
归根结底,我宁愿调用一个现有的文件复制函数,也不愿自己编写并测试一个。
英文原文
展开英文原文
Sorry, I've been so busy lately I've been skimming messages and I still can't keep up.
We want to avoid Windows API calls whenever possible. They usually take about 6-8 parameters and a lot of testing to get right, it takes a page of code to do something simple.
I usually shy away from iostreams. Seems like I too often hit limitations. They kind of botched the C++ streams standard in the 90's, which is too bad, streams can be very powerful and useful when done right. Using it in rpc.cpp may still turn out to be a mistake.
Bottom line is I'd rather call an existing file copy function than make and test my own.