Re: [Patch] httpd.h - delete unused field and enum
Yeah, fine. Sebastian Benoit wrote: > Ross L Richardson(open...@rlr.id.au) on 2020.07.15 14:49:23 +1000: > > Field kv_type in struct kv is not used. As that's the only use of > > enum key_type, delete them both. > > This is probably because its a copy from relayd. > I dont think there is a reason to keep it. > > i'd like to commit, anyone else to ok it? > > > > > > Ross > > > > > > Index: httpd.h > > === > > RCS file: /cvs/src/usr.sbin/httpd/httpd.h,v > > retrieving revision 1.146 > > diff -u -p -r1.146 httpd.h > > --- httpd.h 9 Feb 2020 09:44:04 - 1.146 > > +++ httpd.h 15 Jul 2020 04:45:16 - > > @@ -121,24 +121,12 @@ struct ctl_flags { > > uint8_t cf_tls_sid[TLS_MAX_SESSION_ID_LENGTH]; > > }; > > > > -enum key_type { > > - KEY_TYPE_NONE = 0, > > - KEY_TYPE_COOKIE, > > - KEY_TYPE_HEADER, > > - KEY_TYPE_PATH, > > - KEY_TYPE_QUERY, > > - KEY_TYPE_URL, > > - KEY_TYPE_MAX > > -}; > > - > > TAILQ_HEAD(kvlist, kv); > > RB_HEAD(kvtree, kv); > > > > struct kv { > > char*kv_key; > > char*kv_value; > > - > > - enum key_typekv_type; > > > > #define KV_FLAG_INVALID 0x01 > > #define KV_FLAG_GLOBBING0x02 > > >
Re: [Patch] httpd.h - delete unused field and enum
Ross L Richardson(open...@rlr.id.au) on 2020.07.15 14:49:23 +1000: > Field kv_type in struct kv is not used. As that's the only use of > enum key_type, delete them both. This is probably because its a copy from relayd. I dont think there is a reason to keep it. i'd like to commit, anyone else to ok it? > > Ross > > > Index: httpd.h > === > RCS file: /cvs/src/usr.sbin/httpd/httpd.h,v > retrieving revision 1.146 > diff -u -p -r1.146 httpd.h > --- httpd.h 9 Feb 2020 09:44:04 - 1.146 > +++ httpd.h 15 Jul 2020 04:45:16 - > @@ -121,24 +121,12 @@ struct ctl_flags { > uint8_t cf_tls_sid[TLS_MAX_SESSION_ID_LENGTH]; > }; > > -enum key_type { > - KEY_TYPE_NONE = 0, > - KEY_TYPE_COOKIE, > - KEY_TYPE_HEADER, > - KEY_TYPE_PATH, > - KEY_TYPE_QUERY, > - KEY_TYPE_URL, > - KEY_TYPE_MAX > -}; > - > TAILQ_HEAD(kvlist, kv); > RB_HEAD(kvtree, kv); > > struct kv { > char*kv_key; > char*kv_value; > - > - enum key_typekv_type; > > #define KV_FLAG_INVALID 0x01 > #define KV_FLAG_GLOBBING 0x02 >
[Patch] httpd.h - delete unused field and enum
Field kv_type in struct kv is not used. As that's the only use of enum key_type, delete them both. Ross Index: httpd.h === RCS file: /cvs/src/usr.sbin/httpd/httpd.h,v retrieving revision 1.146 diff -u -p -r1.146 httpd.h --- httpd.h 9 Feb 2020 09:44:04 - 1.146 +++ httpd.h 15 Jul 2020 04:45:16 - @@ -121,24 +121,12 @@ struct ctl_flags { uint8_t cf_tls_sid[TLS_MAX_SESSION_ID_LENGTH]; }; -enum key_type { - KEY_TYPE_NONE = 0, - KEY_TYPE_COOKIE, - KEY_TYPE_HEADER, - KEY_TYPE_PATH, - KEY_TYPE_QUERY, - KEY_TYPE_URL, - KEY_TYPE_MAX -}; - TAILQ_HEAD(kvlist, kv); RB_HEAD(kvtree, kv); struct kv { char*kv_key; char*kv_value; - - enum key_typekv_type; #define KV_FLAG_INVALID 0x01 #define KV_FLAG_GLOBBING0x02