Use \c@chapter instead of \thechapter to check what sectioning unit is used

In ubuntu precise, the old condition; \thechapter is defined or not
misdetects the sectioning unit. And then, it causes build error.
This commit is contained in:
Takeshi KOMIYA 2016-06-11 15:41:27 +09:00
parent d7dd00a898
commit fec2a36db7

View File

@ -841,7 +841,7 @@
% Define literal-block environment
\RequirePackage{newfloat}
\DeclareFloatingEnvironment{literal-block}
\ifx\thechapter\undefined
\ifx\c@chapter\undefined
\SetupFloatingEnvironment{literal-block}{within=section,placement=h}
\else
\SetupFloatingEnvironment{literal-block}{within=chapter,placement=h}