Throw const on some strings

In C, const indicates to the reader that mutation will not occur.
It can also serve as a hint about ownership.

Add const in a few places where it makes sense.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ryan Moeller <freqlabs@FreeBSD.org>
Closes #10997
This commit is contained in:
Ryan Moeller
2020-10-02 20:44:10 -04:00
committed by GitHub
parent 5b525165e9
commit 4d55ea811d
20 changed files with 99 additions and 108 deletions
+1 -1
View File
@@ -203,7 +203,7 @@ spa_features_check(spa_t *spa, boolean_t for_write,
supported = B_FALSE;
if (NULL != unsup_feat) {
char *desc = "";
const char *desc = "";
if (zap_lookup(os, spa->spa_feat_desc_obj,
za->za_name, 1, MAXPATHLEN, buf) == 0)