X-Git-Url: https://git.distorted.org.uk/~mdw/sod/blobdiff_plain/b352f3a30a23f5354a292e37cf8e387d8fced4ab..23e44cba8fe33e8cdde22d1ae14d78d992b9f8bb:/doc/sod.sty

diff --git a/doc/sod.sty b/doc/sod.sty
index 105a6c7..7a52605 100644
--- a/doc/sod.sty
+++ b/doc/sod.sty
@@ -152,7 +152,10 @@
   \vspace{\bigskipamount}%
   \setbox\z@\hbox{\bfseries[\describecategoryname{#2}]}%
   \dimen@\linewidth\advance\dimen@-\wd\z@%
-  \def\@temp##1 ##2\q@{\message{#2:##1}\label{#2:##1}}%
+  \def\@temp##1 ##2\q@{%
+    \message{#2:##1}%
+    {\def\@uscore####1{-}\edef\@tempb{\noexpand\label{#2:##1}}\@tempb}%
+  }%
   \def\@tempa{#1}\ifx\@tempa\q@\@temp#3 \q@\else\@temp{#1} \q@\fi%
   \edef\@temp{{\the\linewidth}{@{}p{\the\dimen@}%
       @{\extracolsep{\fill}}l@{\extracolsep{0pt}}}}%
