wsutil: rename frequency-utils.[ch] to 802_11-utils.[ch].

It's 802.11-specific, and may include non-frequency/channel-related
items in the future.
This commit is contained in:
Guy Harris 2021-03-04 15:41:00 -08:00
parent e60bdb8d9a
commit 25d44cde11
11 changed files with 24 additions and 22 deletions

View File

@ -17,7 +17,7 @@
#include <epan/crypt/dot11decrypt_ws.h>
#include <epan/strutil.h>
#include <wsutil/file_util.h>
#include <wsutil/frequency-utils.h>
#include <wsutil/802_11-utils.h>
#include <caputils/airpcap.h>
#include <caputils/airpcap_loader.h>

View File

@ -15,7 +15,7 @@
#include <wiretap/wtap.h>
#include <wsutil/frequency-utils.h>
#include <wsutil/802_11-utils.h>
void proto_register_netmon_802_11(void);
void proto_reg_handoff_netmon_802_11(void);

View File

@ -19,7 +19,7 @@
#include <epan/capture_dissectors.h>
#include <wsutil/pint.h>
#include <epan/crc32-tvb.h>
#include <wsutil/frequency-utils.h>
#include <wsutil/802_11-utils.h>
#include <epan/tap.h>
#include <epan/prefs.h>
#include <epan/addr_resolv.h>

View File

@ -16,7 +16,7 @@
#include <epan/capture_dissectors.h>
#include <wiretap/wtap.h>
#include <wsutil/pint.h>
#include <wsutil/frequency-utils.h>
#include <wsutil/802_11-utils.h>
#include "packet-ieee80211.h"

View File

@ -26,7 +26,7 @@
#include <epan/prefs.h>
#include <epan/expert.h>
#include <epan/reassemble.h>
#include <wsutil/frequency-utils.h>
#include <wsutil/802_11-utils.h>
#include <wsutil/pint.h>
#include <wsutil/str_util.h>

View File

@ -21,7 +21,7 @@
#include "ui/ws_ui_util.h"
#include <wsutil/utf8_entities.h>
#include <wsutil/frequency-utils.h>
#include <wsutil/802_11-utils.h>
#include "wireshark_application.h"
#include <QProcess>

View File

@ -31,7 +31,7 @@
#include "file_wrappers.h"
#include "commview.h"
#include <wsutil/frequency-utils.h>
#include <wsutil/802_11-utils.h>
typedef struct commview_header {
guint16 data_len;

View File

@ -25,7 +25,7 @@
#include "wtap-int.h"
#include "file_wrappers.h"
#include "peektagged.h"
#include <wsutil/frequency-utils.h>
#include <wsutil/802_11-utils.h>
/* CREDITS
*

View File

@ -1,5 +1,5 @@
/* frequency-utils.c
* Frequency conversion utility definitions
/* 802_11-utils.c
* 802.11 utility definitions
*
* Wireshark - Network traffic analyzer
* By Gerald Combs <gerald@wireshark.org>
@ -12,7 +12,7 @@
#include <glib.h>
#include "frequency-utils.h"
#include "802_11-utils.h"
typedef struct freq_cvt_s {
guint fmin; /* Minimum frequency in MHz */

View File

@ -1,5 +1,5 @@
/* frequency-utils.h
* Frequency conversion utility definitions
/* 802_11-utils.h
* 802.11 utility definitions
*
* Wireshark - Network traffic analyzer
* By Gerald Combs <gerald@wireshark.org>
@ -8,8 +8,8 @@
* SPDX-License-Identifier: GPL-2.0-or-later
*/
#ifndef __FREQUENCY_UTILS_H__
#define __FREQUENCY_UTILS_H__
#ifndef __802_11_UTILS_H__
#define __802_11_UTILS_H__
#include "ws_symbol_export.h"
@ -18,7 +18,7 @@ extern "C" {
#endif /* __cplusplus */
/** @file
* Frequency and channel conversion utilities.
* 802.11 utilities.
*/
/**
@ -31,7 +31,7 @@ gint
ieee80211_mhz_to_chan(guint freq);
/**
* Given a channel number and a band type, return a center frequency.
* Given an 802.11 channel number and a band type, return a center frequency.
* @param chan Channel number
* @param is_bg TRUE if the channel is a b/g channel, FALSE otherwise.
* @return The equivalent frequency or 0 if no match is found.
@ -41,9 +41,11 @@ guint
ieee80211_chan_to_mhz(gint chan, gboolean is_bg);
/**
* Given a frequency in MHz, return a string representation.
* Given an 802.11 channel center frequency in MHz, return a string
* representation.
* @param freq Frequench in MHz.
* @return A string showing the frequency, channel number, and type. The string must be freed with g_free() after use.
* @return A string showing the frequency, channel number, and type.
* The string must be freed with g_free() after use.
*/
WS_DLL_PUBLIC
gchar*
@ -56,7 +58,7 @@ ieee80211_mhz_to_str(guint freq);
}
#endif /* __cplusplus */
#endif /* __FREQUENCY_UTILS_H__ */
#endif /* __802_11_UTILS_H__ */
/*
* Editor modelines

View File

@ -12,6 +12,7 @@ add_definitions(-DEXTCAP_DIR=\"${CMAKE_INSTALL_PREFIX}/${EXTCAP_INSTALL_LIBDIR}\
add_definitions(-DDATA_DIR=\"${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATADIR}\")
set(WSUTIL_PUBLIC_HEADERS
802_11-utils.h
adler32.h
base32.h
bits_count_ones.h
@ -36,7 +37,6 @@ set(WSUTIL_PUBLIC_HEADERS
eax.h
epochs.h
filesystem.h
frequency-utils.h
g711.h
inet_addr.h
inet_ipv4.h
@ -75,6 +75,7 @@ set(WSUTIL_PUBLIC_HEADERS
)
set(WSUTIL_COMMON_FILES
802_11-utils.c
adler32.c
base32.c
bitswap.c
@ -95,7 +96,6 @@ set(WSUTIL_COMMON_FILES
dot11decrypt_wep.c
eax.c
filesystem.c
frequency-utils.c
g711.c
inet_addr.c
interface.c