Skip to content

Commit f1782c6

Browse files
authored
quantize : fail fast on write errors (#3521)
1 parent c26765a commit f1782c6

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

llama.cpp

+1
Original file line numberDiff line numberDiff line change
@@ -7194,6 +7194,7 @@ static void llama_model_quantize_internal(const std::string & fname_inp, const s
71947194
}
71957195

71967196
std::ofstream fout(fname_out, std::ios::binary);
7197+
fout.exceptions(std::ofstream::failbit); // fail fast on write errors
71977198

71987199
const size_t meta_size = gguf_get_meta_size(ctx_out);
71997200

0 commit comments

Comments
 (0)