diff options
Diffstat (limited to 'src')
50 files changed, 60 insertions, 70 deletions
diff --git a/src/IcyMetaDataParser.hxx b/src/IcyMetaDataParser.hxx index 683602c26..def1b9fb3 100644 --- a/src/IcyMetaDataParser.hxx +++ b/src/IcyMetaDataParser.hxx @@ -24,10 +24,9 @@ #include "tag/Tag.hxx" #include "config.h" +#include <cstddef> #include <memory> -#include <stddef.h> - class IcyMetaDataParser { size_t data_size = 0, data_rest; diff --git a/src/MusicChunk.hxx b/src/MusicChunk.hxx index 17bd58606..595233836 100644 --- a/src/MusicChunk.hxx +++ b/src/MusicChunk.hxx @@ -29,10 +29,10 @@ #include "pcm/AudioFormat.hxx" #endif +#include <cstddef> #include <memory> #include <stdint.h> -#include <stddef.h> static constexpr size_t CHUNK_SIZE = 4096; diff --git a/src/client/Client.hxx b/src/client/Client.hxx index c94350b51..b9692ab48 100644 --- a/src/client/Client.hxx +++ b/src/client/Client.hxx @@ -31,12 +31,11 @@ #include <boost/intrusive/link_mode.hpp> #include <boost/intrusive/list_hook.hpp> -#include <set> -#include <string> +#include <cstddef> #include <list> #include <memory> - -#include <stddef.h> +#include <set> +#include <string> class SocketAddress; class UniqueSocketDescriptor; diff --git a/src/client/Response.hxx b/src/client/Response.hxx index b2c72cf48..437ee69ef 100644 --- a/src/client/Response.hxx +++ b/src/client/Response.hxx @@ -24,8 +24,7 @@ #include "util/Compiler.h" #include <cstdarg> - -#include <stddef.h> +#include <cstddef> template<typename T> struct ConstBuffer; class Client; diff --git a/src/config/Parser.hxx b/src/config/Parser.hxx index 1687ae66b..93fccaa53 100644 --- a/src/config/Parser.hxx +++ b/src/config/Parser.hxx @@ -20,7 +20,7 @@ #ifndef MPD_CONFIG_PARSER_HXX #define MPD_CONFIG_PARSER_HXX -#include <stddef.h> +#include <cstddef> /** * Throws on error. diff --git a/src/decoder/DecoderBuffer.hxx b/src/decoder/DecoderBuffer.hxx index c1f267cc1..8040e9641 100644 --- a/src/decoder/DecoderBuffer.hxx +++ b/src/decoder/DecoderBuffer.hxx @@ -24,7 +24,8 @@ #include "util/DynamicFifoBuffer.hxx" #include "util/ConstBuffer.hxx" -#include <stddef.h> +#include <cstddef> + #include <stdint.h> class DecoderClient; diff --git a/src/decoder/plugins/OpusHead.hxx b/src/decoder/plugins/OpusHead.hxx index d73bcdb76..717f5038c 100644 --- a/src/decoder/plugins/OpusHead.hxx +++ b/src/decoder/plugins/OpusHead.hxx @@ -20,7 +20,7 @@ #ifndef MPD_OPUS_HEAD_HXX #define MPD_OPUS_HEAD_HXX -#include <stddef.h> +#include <cstddef> bool ScanOpusHeader(const void *data, size_t size, unsigned &channels_r); diff --git a/src/decoder/plugins/OpusTags.hxx b/src/decoder/plugins/OpusTags.hxx index 5a07363f8..453cdb83e 100644 --- a/src/decoder/plugins/OpusTags.hxx +++ b/src/decoder/plugins/OpusTags.hxx @@ -20,7 +20,7 @@ #ifndef MPD_OPUS_TAGS_HXX #define MPD_OPUS_TAGS_HXX -#include <stddef.h> +#include <cstddef> struct ReplayGainInfo; class TagHandler; diff --git a/src/encoder/EncoderInterface.hxx b/src/encoder/EncoderInterface.hxx index 33e21c7ae..3730bb3d8 100644 --- a/src/encoder/EncoderInterface.hxx +++ b/src/encoder/EncoderInterface.hxx @@ -24,8 +24,7 @@ #include "util/Compiler.h" #include <cassert> - -#include <stddef.h> +#include <cstddef> struct AudioFormat; struct Tag; diff --git a/src/event/PollGroupPoll.hxx b/src/event/PollGroupPoll.hxx index b8dc9c96e..be14fc71b 100644 --- a/src/event/PollGroupPoll.hxx +++ b/src/event/PollGroupPoll.hxx @@ -22,10 +22,10 @@ #include "PollResultGeneric.hxx" +#include <cstddef> #include <vector> #include <unordered_map> -#include <stddef.h> #include <sys/poll.h> class PollGroupPoll diff --git a/src/event/PollResultGeneric.hxx b/src/event/PollResultGeneric.hxx index 3df2ef8e9..6ba466512 100644 --- a/src/event/PollResultGeneric.hxx +++ b/src/event/PollResultGeneric.hxx @@ -20,10 +20,9 @@ #ifndef MPD_EVENT_POLLRESULT_GENERIC_HXX #define MPD_EVENT_POLLRESULT_GENERIC_HXX +#include <cstddef> #include <vector> -#include <stddef.h> - class PollResultGeneric { struct Item diff --git a/src/event/SocketMonitor.hxx b/src/event/SocketMonitor.hxx index 9792b96c2..321b36b72 100644 --- a/src/event/SocketMonitor.hxx +++ b/src/event/SocketMonitor.hxx @@ -24,10 +24,9 @@ #include "net/SocketDescriptor.hxx" #include <cassert> +#include <cstddef> #include <type_traits> -#include <stddef.h> - class EventLoop; /** diff --git a/src/fs/Limits.hxx b/src/fs/Limits.hxx index f9f0b905c..cc3bcaaa1 100644 --- a/src/fs/Limits.hxx +++ b/src/fs/Limits.hxx @@ -21,8 +21,7 @@ #define MPD_FS_LIMITS_HXX #include <climits> - -#include <stddef.h> +#include <cstddef> #if defined(_WIN32) static constexpr size_t MPD_PATH_MAX = 260; diff --git a/src/fs/io/BufferedOutputStream.hxx b/src/fs/io/BufferedOutputStream.hxx index bc8fc0571..657846b53 100644 --- a/src/fs/io/BufferedOutputStream.hxx +++ b/src/fs/io/BufferedOutputStream.hxx @@ -33,7 +33,7 @@ #include "util/Compiler.h" #include "util/DynamicFifoBuffer.hxx" -#include <stddef.h> +#include <cstddef> #ifdef _UNICODE #include <wchar.h> diff --git a/src/fs/io/BufferedReader.hxx b/src/fs/io/BufferedReader.hxx index 048558930..819b74e6d 100644 --- a/src/fs/io/BufferedReader.hxx +++ b/src/fs/io/BufferedReader.hxx @@ -33,7 +33,7 @@ #include "util/Compiler.h" #include "util/DynamicFifoBuffer.hxx" -#include <stddef.h> +#include <cstddef> class Reader; diff --git a/src/fs/io/OutputStream.hxx b/src/fs/io/OutputStream.hxx index 4cb73c14e..465af8b96 100644 --- a/src/fs/io/OutputStream.hxx +++ b/src/fs/io/OutputStream.hxx @@ -30,7 +30,7 @@ #ifndef OUTPUT_STREAM_HXX #define OUTPUT_STREAM_HXX -#include <stddef.h> +#include <cstddef> class OutputStream { public: diff --git a/src/fs/io/Reader.hxx b/src/fs/io/Reader.hxx index 547d27a56..b75f73cc3 100644 --- a/src/fs/io/Reader.hxx +++ b/src/fs/io/Reader.hxx @@ -32,7 +32,7 @@ #include "util/Compiler.h" -#include <stddef.h> +#include <cstddef> /** * An interface that can read bytes from a stream until the stream diff --git a/src/input/cache/Config.hxx b/src/input/cache/Config.hxx index 486f759b2..674e86edc 100644 --- a/src/input/cache/Config.hxx +++ b/src/input/cache/Config.hxx @@ -20,7 +20,7 @@ #ifndef MPD_INPUT_CACHE_CONFIG_HXX #define MPD_INPUT_CACHE_CONFIG_HXX -#include <stddef.h> +#include <cstddef> struct ConfigBlock; diff --git a/src/java/String.hxx b/src/java/String.hxx index 7cd7f2c13..adf8f8182 100644 --- a/src/java/String.hxx +++ b/src/java/String.hxx @@ -34,10 +34,9 @@ #include <jni.h> +#include <cstddef> #include <string> -#include <stddef.h> - namespace Java { /** * Wrapper for a local "jstring" reference. diff --git a/src/lib/crypto/Base64.hxx b/src/lib/crypto/Base64.hxx index 54bffde1b..1997eca88 100644 --- a/src/lib/crypto/Base64.hxx +++ b/src/lib/crypto/Base64.hxx @@ -30,7 +30,7 @@ #ifndef BASE64_HXX #define BASE64_HXX -#include <stddef.h> +#include <cstddef> template<typename T> struct WritableBuffer; struct StringView; diff --git a/src/lib/ffmpeg/Buffer.hxx b/src/lib/ffmpeg/Buffer.hxx index 85a9129d6..cab4375d9 100644 --- a/src/lib/ffmpeg/Buffer.hxx +++ b/src/lib/ffmpeg/Buffer.hxx @@ -24,7 +24,7 @@ extern "C" { #include <libavutil/mem.h> } -#include <stddef.h> +#include <cstddef> /* suppress the ffmpeg compatibility macro */ #ifdef SampleFormat diff --git a/src/lib/nfs/FileReader.hxx b/src/lib/nfs/FileReader.hxx index 60644aea1..ed537f442 100644 --- a/src/lib/nfs/FileReader.hxx +++ b/src/lib/nfs/FileReader.hxx @@ -25,11 +25,11 @@ #include "event/DeferEvent.hxx" #include "util/Compiler.h" -#include <string> +#include <cstddef> #include <exception> +#include <string> #include <stdint.h> -#include <stddef.h> #include <sys/stat.h> struct nfsfh; diff --git a/src/lib/xiph/OggSyncState.hxx b/src/lib/xiph/OggSyncState.hxx index bfb84b7e7..af822c3c4 100644 --- a/src/lib/xiph/OggSyncState.hxx +++ b/src/lib/xiph/OggSyncState.hxx @@ -22,7 +22,8 @@ #include <ogg/ogg.h> -#include <stddef.h> +#include <cstddef> + #include <stdint.h> class Reader; diff --git a/src/output/plugins/PulseOutputPlugin.cxx b/src/output/plugins/PulseOutputPlugin.cxx index 54ae119a6..0220423bf 100644 --- a/src/output/plugins/PulseOutputPlugin.cxx +++ b/src/output/plugins/PulseOutputPlugin.cxx @@ -34,9 +34,9 @@ #include <pulse/version.h> #include <cassert> +#include <cstddef> #include <stdexcept> -#include <stddef.h> #include <stdlib.h> #define MPD_PULSE_NAME "Music Player Daemon" diff --git a/src/output/plugins/httpd/HttpdClient.hxx b/src/output/plugins/httpd/HttpdClient.hxx index 8c291cb1d..cfd7d80c5 100644 --- a/src/output/plugins/httpd/HttpdClient.hxx +++ b/src/output/plugins/httpd/HttpdClient.hxx @@ -27,10 +27,9 @@ #include <boost/intrusive/link_mode.hpp> #include <boost/intrusive/list_hook.hpp> -#include <queue> +#include <cstddef> #include <list> - -#include <stddef.h> +#include <queue> class UniqueSocketDescriptor; class HttpdOutput; diff --git a/src/output/plugins/httpd/Page.hxx b/src/output/plugins/httpd/Page.hxx index c174a6309..c575d04d9 100644 --- a/src/output/plugins/httpd/Page.hxx +++ b/src/output/plugins/httpd/Page.hxx @@ -22,9 +22,8 @@ #include "util/AllocatedArray.hxx" +#include <cstddef> #include <memory> - -#include <stddef.h> #include <stdint.h> /** diff --git a/src/pcm/AudioFormat.hxx b/src/pcm/AudioFormat.hxx index 710ea7e25..7d931a002 100644 --- a/src/pcm/AudioFormat.hxx +++ b/src/pcm/AudioFormat.hxx @@ -24,10 +24,9 @@ #include "pcm/ChannelDefs.hxx" #include "util/Compiler.h" +#include <cstddef> #include <cstdint> -#include <stddef.h> - template<size_t CAPACITY> class StringBuffer; /** diff --git a/src/pcm/Dsd2Pcm.hxx b/src/pcm/Dsd2Pcm.hxx index afe1eaebe..42a422d9b 100644 --- a/src/pcm/Dsd2Pcm.hxx +++ b/src/pcm/Dsd2Pcm.hxx @@ -34,8 +34,8 @@ or implied, of Sebastian Gesemann. #include "ChannelDefs.hxx" #include <array> +#include <cstddef> -#include <stddef.h> #include <stdint.h> /** diff --git a/src/pcm/Mix.hxx b/src/pcm/Mix.hxx index 745c1e6f5..f3aea7f73 100644 --- a/src/pcm/Mix.hxx +++ b/src/pcm/Mix.hxx @@ -23,7 +23,7 @@ #include "SampleFormat.hxx" #include "util/Compiler.h" -#include <stddef.h> +#include <cstddef> class PcmDither; diff --git a/src/pcm/RestBuffer.hxx b/src/pcm/RestBuffer.hxx index 366753d90..361ed059a 100644 --- a/src/pcm/RestBuffer.hxx +++ b/src/pcm/RestBuffer.hxx @@ -24,8 +24,7 @@ #include <algorithm> #include <cassert> - -#include <stddef.h> +#include <cstddef> template<typename T> struct ConstBuffer; class PcmBuffer; diff --git a/src/pcm/Traits.hxx b/src/pcm/Traits.hxx index 155c895c4..f36156714 100644 --- a/src/pcm/Traits.hxx +++ b/src/pcm/Traits.hxx @@ -22,8 +22,9 @@ #include "SampleFormat.hxx" +#include <cstddef> + #include <stdint.h> -#include <stddef.h> /** * This template describes the specified #SampleFormat. This is an diff --git a/src/tag/Aiff.hxx b/src/tag/Aiff.hxx index 43103963b..b3bebb60b 100644 --- a/src/tag/Aiff.hxx +++ b/src/tag/Aiff.hxx @@ -27,7 +27,7 @@ #include "thread/Mutex.hxx" -#include <stddef.h> +#include <cstddef> class InputStream; diff --git a/src/tag/Riff.hxx b/src/tag/Riff.hxx index 3aa4d4666..7ffcd1f9b 100644 --- a/src/tag/Riff.hxx +++ b/src/tag/Riff.hxx @@ -27,7 +27,7 @@ #include "thread/Mutex.hxx" -#include <stddef.h> +#include <cstddef> class InputStream; diff --git a/src/time/ISO8601.hxx b/src/time/ISO8601.hxx index 061e8f529..eec40da69 100644 --- a/src/time/ISO8601.hxx +++ b/src/time/ISO8601.hxx @@ -38,7 +38,7 @@ #include <chrono> #include <utility> -#include <stddef.h> +#include <cstddef> struct tm; template<size_t CAPACITY> class StringBuffer; diff --git a/src/util/Alloc.hxx b/src/util/Alloc.hxx index 93a193807..48a0c870c 100644 --- a/src/util/Alloc.hxx +++ b/src/util/Alloc.hxx @@ -22,7 +22,7 @@ #include "Compiler.h" -#include <stddef.h> +#include <cstddef> /** * Allocate memory. Use free() to free it. diff --git a/src/util/ByteReverse.hxx b/src/util/ByteReverse.hxx index 7764ae985..842338ffb 100644 --- a/src/util/ByteReverse.hxx +++ b/src/util/ByteReverse.hxx @@ -20,8 +20,9 @@ #ifndef MPD_BYTE_REVERSE_HXX #define MPD_BYTE_REVERSE_HXX +#include <cstddef> + #include <stdint.h> -#include <stddef.h> /** * Reverse the bytes in each 16 bit "frame". This function can be diff --git a/src/util/Cast.hxx b/src/util/Cast.hxx index 05871df64..ad0502af6 100644 --- a/src/util/Cast.hxx +++ b/src/util/Cast.hxx @@ -33,7 +33,7 @@ #include "OffsetPointer.hxx" #include "Compiler.h" -#include <stddef.h> +#include <cstddef> template<typename T, typename U> constexpr T * diff --git a/src/util/CircularBuffer.hxx b/src/util/CircularBuffer.hxx index bff34113c..de1c5dfdd 100644 --- a/src/util/CircularBuffer.hxx +++ b/src/util/CircularBuffer.hxx @@ -33,8 +33,7 @@ #include "WritableBuffer.hxx" #include <cassert> - -#include <stddef.h> +#include <cstddef> /** * A circular buffer. diff --git a/src/util/HexFormat.hxx b/src/util/HexFormat.hxx index d0eab03e6..0f62ad0df 100644 --- a/src/util/HexFormat.hxx +++ b/src/util/HexFormat.hxx @@ -34,7 +34,8 @@ #include "StringBuffer.hxx" #include "Compiler.h" -#include <stddef.h> +#include <cstddef> + #include <stdint.h> /** diff --git a/src/util/HugeAllocator.hxx b/src/util/HugeAllocator.hxx index 63ecc43eb..e36ba3895 100644 --- a/src/util/HugeAllocator.hxx +++ b/src/util/HugeAllocator.hxx @@ -32,10 +32,9 @@ #include "WritableBuffer.hxx" +#include <cstddef> #include <utility> -#include <stddef.h> - #ifdef __linux__ /** diff --git a/src/util/OffsetPointer.hxx b/src/util/OffsetPointer.hxx index a1fb03f2a..383f7271e 100644 --- a/src/util/OffsetPointer.hxx +++ b/src/util/OffsetPointer.hxx @@ -29,7 +29,7 @@ #pragma once -#include <stddef.h> +#include <cstddef> /** * Offset the given pointer by the specified number of bytes. diff --git a/src/util/PeakBuffer.hxx b/src/util/PeakBuffer.hxx index f0c2722c1..300f7573a 100644 --- a/src/util/PeakBuffer.hxx +++ b/src/util/PeakBuffer.hxx @@ -22,7 +22,8 @@ #include "Compiler.h" -#include <stddef.h> +#include <cstddef> + #include <stdint.h> template<typename T> struct WritableBuffer; diff --git a/src/util/ReusableArray.hxx b/src/util/ReusableArray.hxx index 706291382..5ff2aa4a6 100644 --- a/src/util/ReusableArray.hxx +++ b/src/util/ReusableArray.hxx @@ -32,10 +32,9 @@ #include "Compiler.h" +#include <cstddef> #include <utility> -#include <stddef.h> - /** * Manager for a temporary array which grows as needed. This attempts * to reduce the number of consecutive heap allocations and diff --git a/src/util/SliceBuffer.hxx b/src/util/SliceBuffer.hxx index 30c4c4c4c..68723d2dc 100644 --- a/src/util/SliceBuffer.hxx +++ b/src/util/SliceBuffer.hxx @@ -24,11 +24,10 @@ #include "Compiler.h" #include <cassert> +#include <cstddef> #include <new> #include <utility> -#include <stddef.h> - /** * This class pre-allocates a certain number of objects, and allows * callers to allocate and free these objects ("slices"). diff --git a/src/util/StringStrip.hxx b/src/util/StringStrip.hxx index 20d0ed925..d09d09655 100644 --- a/src/util/StringStrip.hxx +++ b/src/util/StringStrip.hxx @@ -32,7 +32,7 @@ #include "Compiler.h" -#include <stddef.h> +#include <cstddef> /** * Skips whitespace at the beginning of the string, and returns the diff --git a/src/util/StringUtil.hxx b/src/util/StringUtil.hxx index d1ded45a4..17c892433 100644 --- a/src/util/StringUtil.hxx +++ b/src/util/StringUtil.hxx @@ -22,7 +22,7 @@ #include "Compiler.h" -#include <stddef.h> +#include <cstddef> struct StringView; diff --git a/src/util/TemplateString.hxx b/src/util/TemplateString.hxx index 5e2e5f494..90c45738b 100644 --- a/src/util/TemplateString.hxx +++ b/src/util/TemplateString.hxx @@ -30,7 +30,7 @@ #ifndef TEMPLATE_STRING_HXX #define TEMPLATE_STRING_HXX -#include <stddef.h> +#include <cstddef> namespace TemplateString { /** diff --git a/src/util/TransformN.hxx b/src/util/TransformN.hxx index 0b6170386..2f716ba67 100644 --- a/src/util/TransformN.hxx +++ b/src/util/TransformN.hxx @@ -30,7 +30,7 @@ #ifndef TRANSFORM_N_HXX #define TRANSFORM_N_HXX -#include <stddef.h> +#include <cstddef> /** * The std::transform_n() function that is missing in the C++ standard diff --git a/src/util/TruncateString.hxx b/src/util/TruncateString.hxx index 997e5cfe9..1da5f6333 100644 --- a/src/util/TruncateString.hxx +++ b/src/util/TruncateString.hxx @@ -32,7 +32,7 @@ #include "Compiler.h" -#include <stddef.h> +#include <cstddef> /** * Copy a string. If the buffer is too small, then the string is diff --git a/src/util/UTF8.hxx b/src/util/UTF8.hxx index 4c3c4f05b..f8dfb553f 100644 --- a/src/util/UTF8.hxx +++ b/src/util/UTF8.hxx @@ -33,7 +33,7 @@ #include "Compiler.h" -#include <stddef.h> +#include <cstddef> /** * Is this a valid UTF-8 string? |