ifcfg-rh/trivial: drop comment for nms_ifcfg_well_known_keys

The comment isn't right. The fixed array size is in the header file,
because other parts of the code need to know how many elements are in
the array. The alternative would be a define for the size, but that
is only redundant information. Also, even with a define the user who
adds an entry needs to adjust the code in the header. Explicitly stating
the array size in the header makes it almost impossible to accidentally
choosing the wrong size, because the compiler (and unit tests) ensure
the consistency.
This commit is contained in:
Thomas Haller 2020-04-24 09:05:25 +02:00
parent bdb1d71cfa
commit 3a2858a2fd

View file

@ -33,7 +33,6 @@ typedef struct {
NMSIfcfgKeyTypeFlags key_flags;
} NMSIfcfgKeyTypeInfo;
/* maybe think about getting rid of the fixed number below at some point.*/
extern const NMSIfcfgKeyTypeInfo nms_ifcfg_well_known_keys[233];
const NMSIfcfgKeyTypeInfo *nms_ifcfg_well_known_key_find_info (const char *key, gssize *out_idx);