You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-12-07 17:36:07 +00:00
Replace NULL with nullptr
This commit is contained in:
@@ -31,7 +31,7 @@
|
||||
#include "packet_peer_gdnative.h"
|
||||
|
||||
PacketPeerGDNative::PacketPeerGDNative() {
|
||||
interface = NULL;
|
||||
interface = nullptr;
|
||||
}
|
||||
|
||||
PacketPeerGDNative::~PacketPeerGDNative() {
|
||||
@@ -45,22 +45,22 @@ void PacketPeerGDNative::_bind_methods() {
|
||||
}
|
||||
|
||||
Error PacketPeerGDNative::get_packet(const uint8_t **r_buffer, int &r_buffer_size) {
|
||||
ERR_FAIL_COND_V(interface == NULL, ERR_UNCONFIGURED);
|
||||
ERR_FAIL_COND_V(interface == nullptr, ERR_UNCONFIGURED);
|
||||
return (Error)interface->get_packet(interface->data, r_buffer, &r_buffer_size);
|
||||
}
|
||||
|
||||
Error PacketPeerGDNative::put_packet(const uint8_t *p_buffer, int p_buffer_size) {
|
||||
ERR_FAIL_COND_V(interface == NULL, ERR_UNCONFIGURED);
|
||||
ERR_FAIL_COND_V(interface == nullptr, ERR_UNCONFIGURED);
|
||||
return (Error)interface->put_packet(interface->data, p_buffer, p_buffer_size);
|
||||
}
|
||||
|
||||
int PacketPeerGDNative::get_max_packet_size() const {
|
||||
ERR_FAIL_COND_V(interface == NULL, 0);
|
||||
ERR_FAIL_COND_V(interface == nullptr, 0);
|
||||
return interface->get_max_packet_size(interface->data);
|
||||
}
|
||||
|
||||
int PacketPeerGDNative::get_available_packet_count() const {
|
||||
ERR_FAIL_COND_V(interface == NULL, 0);
|
||||
ERR_FAIL_COND_V(interface == nullptr, 0);
|
||||
return interface->get_available_packet_count(interface->data);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user