Skip to content

Commit a196d1d

Browse files
committed
decoder/Thread, ...: quote log strings
1 parent 8861279 commit a196d1d

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

src/archive/plugins/Iso9660ArchivePlugin.cxx

+2-2
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ struct Iso9660 {
3131
explicit Iso9660(Path path)
3232
:iso(iso9660_open(path.c_str())) {
3333
if (iso == nullptr)
34-
throw FmtRuntimeError("Failed to open ISO9660 file {}",
34+
throw FmtRuntimeError("Failed to open ISO9660 file {:?}",
3535
path);
3636
}
3737

@@ -223,7 +223,7 @@ Iso9660ArchiveFile::OpenStream(const char *pathname,
223223
{
224224
auto statbuf = iso9660_ifs_stat_translate(iso->iso, pathname);
225225
if (statbuf == nullptr)
226-
throw FmtRuntimeError("not found in the ISO file: {}",
226+
throw FmtRuntimeError("not found in the ISO file: {:?}",
227227
pathname);
228228

229229
const lsn_t lsn = statbuf->lsn;

src/config/File.cxx

+3-3
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ ReadConfigFile(ConfigData &config_data, BufferedReader &reader, Path directory)
211211
ReadConfigBlock(config_data, reader, name, bo,
212212
tokenizer);
213213
} else {
214-
throw FmtRuntimeError("unrecognized parameter: {}",
214+
throw FmtRuntimeError("unrecognized parameter: {:?}",
215215
name);
216216
}
217217
}
@@ -222,7 +222,7 @@ ReadConfigFile(ConfigData &config_data, Path path)
222222
{
223223
assert(!path.IsNull());
224224

225-
FmtDebug(config_file_domain, "loading file {}", path);
225+
FmtDebug(config_file_domain, "loading file {:?}", path);
226226

227227
FileReader file(path);
228228

@@ -231,7 +231,7 @@ ReadConfigFile(ConfigData &config_data, Path path)
231231
try {
232232
ReadConfigFile(config_data, reader, path.GetDirectoryName());
233233
} catch (...) {
234-
std::throw_with_nested(FmtRuntimeError("Error in {} line {}",
234+
std::throw_with_nested(FmtRuntimeError("Error in {:?} line {}",
235235
path,
236236
reader.GetLineNumber()));
237237
}

src/config/Path.cxx

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ GetHome(const char *user)
2424
{
2525
AllocatedPath result = GetHomeDir(user);
2626
if (result.IsNull())
27-
throw FmtRuntimeError("no such user: {}", user);
27+
throw FmtRuntimeError("no such user: {:?}", user);
2828

2929
return result;
3030
}
@@ -91,7 +91,7 @@ ParsePath(const char *path)
9191
/ AllocatedPath::FromUTF8Throw(rest);
9292
}
9393
} else if (!PathTraitsUTF8::IsAbsolute(path)) {
94-
throw FmtRuntimeError("not an absolute path: {}", path);
94+
throw FmtRuntimeError("not an absolute path: {:?}", path);
9595
} else {
9696
#endif
9797
return AllocatedPath::FromUTF8Throw(path);

src/decoder/Thread.cxx

+1-1
Original file line numberDiff line numberDiff line change
@@ -439,7 +439,7 @@ try {
439439
if (!allocated.empty())
440440
error_uri = allocated.c_str();
441441

442-
std::throw_with_nested(FmtRuntimeError("Failed to decode {}",
442+
std::throw_with_nested(FmtRuntimeError("Failed to decode {:?}",
443443
error_uri));
444444
}
445445

0 commit comments

Comments
 (0)