summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAaron Plattner <aplattner@nvidia.com>2014-08-06 07:43:18 -0700
committerAaron Plattner <aplattner@nvidia.com>2014-08-06 07:43:18 -0700
commit4ac119c37dae1e74ac12e2402433f17696b89b71 (patch)
tree354398c36099661c16ad0cd743ba3896bd0d9c6a
parent1823aaf84dd0fe1c6ce263d28f325d91665c04bb (diff)
343.13343.13
-rw-r--r--common-utils/gen-manpage-opts-helper.c21
-rw-r--r--version.mk2
2 files changed, 20 insertions, 3 deletions
diff --git a/common-utils/gen-manpage-opts-helper.c b/common-utils/gen-manpage-opts-helper.c
index c05ef38..84bac62 100644
--- a/common-utils/gen-manpage-opts-helper.c
+++ b/common-utils/gen-manpage-opts-helper.c
@@ -90,7 +90,9 @@ static void print_option(const NVGetoptOption *o)
* '&' : toggles italics on and off
* '^' : toggles bold on and off
* '-' : is backslashified: "\-"
+ * '\n': resets the first character flag
* '.' : must not be the first character of a line
+ * '\'': must not be the first character of a line
*
* Trailing whitespace is omitted when italics or bold is on
*/
@@ -110,8 +112,8 @@ static void print_option(const NVGetoptOption *o)
printf("\n.I ");
}
omitWhiteSpace = italics;
+ firstchar = italics;
italics = !italics;
- firstchar = TRUE;
break;
case '^':
if (bold) {
@@ -120,8 +122,8 @@ static void print_option(const NVGetoptOption *o)
printf("\n.B ");
}
omitWhiteSpace = bold;
+ firstchar = bold;
bold = !bold;
- firstchar = TRUE;
break;
case '-':
printf("\\-");
@@ -134,6 +136,11 @@ static void print_option(const NVGetoptOption *o)
firstchar = FALSE;
}
break;
+ case '\n':
+ printf("\n");
+ omitWhiteSpace = FALSE;
+ firstchar = TRUE;
+ break;
case '.':
if (firstchar) {
fprintf(stderr, "Error: *roff can't start a line with '.' "
@@ -144,6 +151,16 @@ static void print_option(const NVGetoptOption *o)
exit(1);
}
/* fall through */
+ case '\'':
+ if (firstchar) {
+ fprintf(stderr, "Error: *roff can't start a line with '\''. "
+ "If you started a line with '\'' in the description "
+ "of the '%s' option, please add some text at the "
+ "beginning of the sentence, so that a valid manpage "
+ "can be generated.\n", o->name);
+ exit(1);
+ }
+ /* fall through */
default:
printf("%c", *s);
omitWhiteSpace = FALSE;
diff --git a/version.mk b/version.mk
index a7b8a27..043e890 100644
--- a/version.mk
+++ b/version.mk
@@ -1 +1 @@
-NVIDIA_VERSION = 340.24
+NVIDIA_VERSION = 343.13