Unexpected end of style sheet in @font-face rule discards it rather than closes all open constructs
https://bugs.webkit.org/show_bug.cgi?id=89980

Reviewed by Antti Koivisto.

Source/WebCore:

Use the "closing_brace" at the end of font_face rather than the explicit "'}' maybe_space".

Test: fast/css/font-face-unexpected-end.html

* css/CSSGrammar.y:

LayoutTests:

* fast/css/font-face-unexpected-end-expected.html: Added.
* fast/css/font-face-unexpected-end.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@121337 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/LayoutTests/fast/css/font-face-unexpected-end.html b/LayoutTests/fast/css/font-face-unexpected-end.html
new file mode 100644
index 0000000..7e66882
--- /dev/null
+++ b/LayoutTests/fast/css/font-face-unexpected-end.html
@@ -0,0 +1,14 @@
+<style>
+    @font-face {
+        font-family: ahem-family;
+        src: url(../../resources/Ahem.otf);
+    /* The @font-face rule has no closing brace, so the style sheet is terminated unexpectedly. */
+</style>
+<p>
+    Test for <i><a href="https://bugs.webkit.org/show_bug.cgi?id=89980">https://bugs.webkit.org/show_bug.cgi?id=89980</a> Unexpected end of style sheet in @font-face rule discards it rather than closes all open constructs</i>.
+</p>
+<p>Check if a @font-face rule without a closing brace is accepted.</p>
+<span style="font-family: ahem-family">0123456789ABCDEF</span>
+<script>
+    document.body.offsetTop;
+</script>