diff --git a/libavutil/error.c b/libavutil/error.c
index ddcc038650298abc98c505a9b4a40672bdf94954..a330e9f99c1f63c9a58c2bc3c8f57bc2671a72de 100644
--- a/libavutil/error.c
+++ b/libavutil/error.c
@@ -38,6 +38,7 @@ int av_strerror(int errnum, char *errbuf, size_t errbuf_size)
     case AVERROR_PATCHWELCOME:      errstr = "Not yet implemented in Libav, patches welcome"; break;
     case AVERROR_PROTOCOL_NOT_FOUND:errstr = "Protocol not found"                           ; break;
     case AVERROR_STREAM_NOT_FOUND:  errstr = "Stream not found"                             ; break;
+    case AVERROR_BUG:               errstr = "Bug detected, please report the issue"        ; break;
     }
 
     if (errstr) {
diff --git a/libavutil/error.h b/libavutil/error.h
index 8ed77342ef199b871182f7da07f33959652c9c23..2db65cb83f7d16c9479100291c7f8bc2d253db78 100644
--- a/libavutil/error.h
+++ b/libavutil/error.h
@@ -57,6 +57,7 @@
 #define AVERROR_PATCHWELCOME       (-MKTAG( 'P','A','W','E')) ///< Not yet implemented in Libav, patches welcome
 #define AVERROR_PROTOCOL_NOT_FOUND (-MKTAG(0xF8,'P','R','O')) ///< Protocol not found
 #define AVERROR_STREAM_NOT_FOUND   (-MKTAG(0xF8,'S','T','R')) ///< Stream not found
+#define AVERROR_BUG                (-MKTAG( 'B','U','G',' ')) ///< Bug detected, please report the issue
 
 /**
  * Put a description of the AVERROR code errnum in errbuf.