Page MenuHomePhabricator

fs: consistently use fsbridge:: for ifstream / ofstream
ClosedPublic

Authored by PiRK on Sep 13 2022, 13:59.

Details

Summary

fs: consistently use fsbridge for {i,o}fstream

fs: add missing <cassert> include

This is needed to prevent compilation failures once boost is removed,
however is still correct to include now, and reduces the diff in #20744.

<string> is extracted from the defines because it is used for Windows
and non-Windows code, i.e get_filesystem_error_message().

fs: consistently use fsbridge for fopen()

This is a backport of core#24167

Depends on D11984

Notes:

  • the psbtoperationsdialog.cpp and fuzz.cpp changes are not applicable due to missing backports
  • the walletframe.cpp changes are in walletview.cpp because of missing backports (core-gui#399)
Test Plan

ninja all check-all

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

PiRK requested review of this revision.Sep 13 2022, 13:59
sdulfari requested changes to this revision.Sep 13 2022, 17:22
sdulfari added a subscriber: sdulfari.

psbtoperationsdialog should be its own backport

This revision now requires changes to proceed.Sep 13 2022, 17:22

drop psbtoperationsdialog

Fabien requested changes to this revision.Sep 20 2022, 09:07
Fabien added a subscriber: Fabien.

The walletframe change is missing (see WalletView::gotoLoadPSBT()).
Also please add a comment in the summary to explain the fuzz and psbt changes are missing backports.

src/qt/sendcoinsdialog.cpp
469 ↗(On Diff #35016)

are you missing a backport for the binary more here ?

This revision now requires changes to proceed.Sep 20 2022, 09:07
PiRK edited the summary of this revision. (Show Details)

add notes to mention missing backports
apply changes in walletview.cpp (see notes)

src/qt/sendcoinsdialog.cpp
469 ↗(On Diff #35016)

Yes, that would have been D11984. Should I do a partial backport of core-gui#188 for this (without psbtoperationsdialog)?
The danger of doing this is that we will likely forget to apply the same fixe to psbtoperationsdialog if we decide to backport it later.

src/qt/sendcoinsdialog.cpp
469 ↗(On Diff #35016)

If this is a bug fix it's worth porting

Fabien requested changes to this revision.Sep 20 2022, 15:09
This revision now requires changes to proceed.Sep 20 2022, 15:09
PiRK edited the summary of this revision. (Show Details)

rebase onto D11984 and apply relevant change to sendcoinsdialog.cpp

This revision is now accepted and ready to land.Sep 20 2022, 15:52
This revision was landed with ongoing or failed builds.Sep 20 2022, 15:55
This revision was automatically updated to reflect the committed changes.