diff --git a/dlib/base64/base64_kernel_1.cpp b/dlib/base64/base64_kernel_1.cpp index 06cae3d95..5b48c789e 100644 --- a/dlib/base64/base64_kernel_1.cpp +++ b/dlib/base64/base64_kernel_1.cpp @@ -190,20 +190,20 @@ namespace dlib case CR: ch = '\r'; if (out.sputn(&ch,1)!=1) - throw std::ios_base::failure("error occured in the base64 object"); + throw std::ios_base::failure("error occurred in the base64 object"); break; case LF: ch = '\n'; if (out.sputn(&ch,1)!=1) - throw std::ios_base::failure("error occured in the base64 object"); + throw std::ios_base::failure("error occurred in the base64 object"); break; case CRLF: ch = '\r'; if (out.sputn(&ch,1)!=1) - throw std::ios_base::failure("error occured in the base64 object"); + throw std::ios_base::failure("error occurred in the base64 object"); ch = '\n'; if (out.sputn(&ch,1)!=1) - throw std::ios_base::failure("error occured in the base64 object"); + throw std::ios_base::failure("error occurred in the base64 object"); break; default: DLIB_CASSERT(false,"this should never happen"); @@ -235,7 +235,7 @@ namespace dlib // write the encoded bytes to the output stream if (out.sputn(reinterpret_cast(&outbuf),4)!=4) { - throw std::ios_base::failure("error occured in the base64 object"); + throw std::ios_base::failure("error occurred in the base64 object"); } // get 3 more input bytes @@ -265,7 +265,7 @@ namespace dlib // write the encoded bytes to the output stream if (out.sputn(reinterpret_cast(&outbuf),4)!=4) { - throw std::ios_base::failure("error occured in the base64 object"); + throw std::ios_base::failure("error occurred in the base64 object"); } @@ -292,7 +292,7 @@ namespace dlib // write the encoded bytes to the output stream if (out.sputn(reinterpret_cast(&outbuf),4)!=4) { - throw std::ios_base::failure("error occured in the base64 object"); + throw std::ios_base::failure("error occurred in the base64 object"); } break; @@ -370,7 +370,7 @@ namespace dlib // write the encoded bytes to the output stream if (out.sputn(reinterpret_cast(&outbuf),outsize)!=outsize) { - throw std::ios_base::failure("error occured in the base64 object"); + throw std::ios_base::failure("error occurred in the base64 object"); } } diff --git a/dlib/bit_stream/bit_stream_kernel_1.cpp b/dlib/bit_stream/bit_stream_kernel_1.cpp index ad3d63ef6..f49db14d5 100644 --- a/dlib/bit_stream/bit_stream_kernel_1.cpp +++ b/dlib/bit_stream/bit_stream_kernel_1.cpp @@ -121,7 +121,7 @@ namespace dlib buffer <<= 8 - buffer_size; if (osp->rdbuf()->sputn(reinterpret_cast(&buffer),1) == 0) { - throw std::ios_base::failure("error occured in the bit_stream object"); + throw std::ios_base::failure("error occurred in the bit_stream object"); } buffer_size = 0; diff --git a/dlib/entropy_encoder/entropy_encoder_kernel_1.cpp b/dlib/entropy_encoder/entropy_encoder_kernel_1.cpp index 028609d05..effcf3123 100644 --- a/dlib/entropy_encoder/entropy_encoder_kernel_1.cpp +++ b/dlib/entropy_encoder/entropy_encoder_kernel_1.cpp @@ -127,7 +127,7 @@ namespace dlib { if (streambuf->sputn(reinterpret_cast(&buf),1)==0) { - throw std::ios_base::failure("error occured in the entropy_encoder object"); + throw std::ios_base::failure("error occurred in the entropy_encoder object"); } buf = 0; buf_used = 0; @@ -189,26 +189,26 @@ namespace dlib } if (streambuf->sputn(reinterpret_cast(&buf),1) == 0) - throw std::ios_base::failure("error occured in the entropy_encoder object"); + throw std::ios_base::failure("error occurred in the entropy_encoder object"); buf = static_cast((low >> 24)&0xFF); if (streambuf->sputn(reinterpret_cast(&buf),1) == 0) - throw std::ios_base::failure("error occured in the entropy_encoder object"); + throw std::ios_base::failure("error occurred in the entropy_encoder object"); buf = static_cast((low >> 16)&0xFF); if (streambuf->sputn(reinterpret_cast(&buf),1)==0) - throw std::ios_base::failure("error occured in the entropy_encoder object"); + throw std::ios_base::failure("error occurred in the entropy_encoder object"); buf = static_cast((low >> 8)&0xFF); if (streambuf->sputn(reinterpret_cast(&buf),1)==0) - throw std::ios_base::failure("error occured in the entropy_encoder object"); + throw std::ios_base::failure("error occurred in the entropy_encoder object"); @@ -216,7 +216,7 @@ namespace dlib { buf = static_cast((low)&0xFF); if (streambuf->sputn(reinterpret_cast(&buf),1)==0) - throw std::ios_base::failure("error occured in the entropy_encoder object"); + throw std::ios_base::failure("error occurred in the entropy_encoder object"); } diff --git a/dlib/entropy_encoder/entropy_encoder_kernel_2.cpp b/dlib/entropy_encoder/entropy_encoder_kernel_2.cpp index d88030f2b..4f64a6155 100644 --- a/dlib/entropy_encoder/entropy_encoder_kernel_2.cpp +++ b/dlib/entropy_encoder/entropy_encoder_kernel_2.cpp @@ -170,7 +170,7 @@ namespace dlib // write buf to the output stream if (streambuf->sputn(reinterpret_cast(&buf),1)==0) { - throw std::ios_base::failure("error occured in the entropy_encoder object"); + throw std::ios_base::failure("error occurred in the entropy_encoder object"); } } @@ -194,25 +194,25 @@ namespace dlib buf = static_cast((low >> 24)&0xFF); if (streambuf->sputn(reinterpret_cast(&buf),1) == 0) - throw std::ios_base::failure("error occured in the entropy_encoder object"); + throw std::ios_base::failure("error occurred in the entropy_encoder object"); buf = static_cast((low >> 16)&0xFF); if (streambuf->sputn(reinterpret_cast(&buf),1)==0) - throw std::ios_base::failure("error occured in the entropy_encoder object"); + throw std::ios_base::failure("error occurred in the entropy_encoder object"); buf = static_cast((low >> 8)&0xFF); if (streambuf->sputn(reinterpret_cast(&buf),1)==0) - throw std::ios_base::failure("error occured in the entropy_encoder object"); + throw std::ios_base::failure("error occurred in the entropy_encoder object"); buf = static_cast((low)&0xFF); if (streambuf->sputn(reinterpret_cast(&buf),1)==0) - throw std::ios_base::failure("error occured in the entropy_encoder object"); + throw std::ios_base::failure("error occurred in the entropy_encoder object");