diff src/goodjava/webserver/RequestParser.java @ 1773:b914a726061f

video multipart
author Franklin Schmidt <fschmidt@gmail.com>
date Tue, 18 Jul 2023 11:56:40 -0600
parents 8df0b80e715e
children
line wrap: on
line diff
--- a/src/goodjava/webserver/RequestParser.java	Sun Jun 25 15:21:08 2023 -0600
+++ b/src/goodjava/webserver/RequestParser.java	Tue Jul 18 11:56:40 2023 -0600
@@ -220,11 +220,13 @@
 					isBinary = true;
 				} else if( parser.match("image/") ) {
 					isBinary = true;
+				} else if( parser.match("video/") ) {
+					isBinary = true;
 				} else if( parser.match("text/") ) {
 					isBinary = false;
 				} else
 					throw new ParseException(parser,"bad file content-type");
-				while( parser.inCharRange('a','z') || parser.anyOf("-.") );
+				while( parser.inCharRange('a','z') || parser.inCharRange('0','9') || parser.anyOf("-.") );
 				contentType = parser.textFrom(start);
 			}
 			require( parser.match("\r\n") );