46 lines
832 B
Diff
46 lines
832 B
Diff
--- a/lib/nwnet.c
|
|
+++ b/lib/nwnet.c
|
|
@@ -212,6 +212,15 @@
|
|
char *o;
|
|
size_t ol;
|
|
int ret;
|
|
+
|
|
+ if (inp == NULL || inl == NULL || outp == NULL || outl == NULL) {
|
|
+ errno = EINVAL;
|
|
+ return -1;
|
|
+ }
|
|
+ if (*inp == NULL || *outp == NULL) {
|
|
+ errno = EINVAL;
|
|
+ return -1;
|
|
+ }
|
|
|
|
ret = 0;
|
|
ol = *outl;
|
|
@@ -324,6 +333,15 @@
|
|
char *o;
|
|
size_t ol;
|
|
int ret;
|
|
+
|
|
+ if (inp == NULL || inl == NULL || outp == NULL || outl == NULL) {
|
|
+ errno = EINVAL;
|
|
+ return -1;
|
|
+ }
|
|
+ if (*inp == NULL || *outp == NULL) {
|
|
+ errno = EINVAL;
|
|
+ return -1;
|
|
+ }
|
|
|
|
ret = 0;
|
|
ol = *outl;
|
|
@@ -2303,6 +2321,10 @@
|
|
|
|
static inline NWDSCCODE NWDSPutAttrVal_DIST_NAME(NWDSContextHandle ctx, Buf_T* buffer,
|
|
const NWDSChar* name) {
|
|
+ if (name == NULL) {
|
|
+ errno = EINVAL;
|
|
+ return ERR_NULL_POINTER;
|
|
+ }
|
|
return NWDSCtxBufDN(ctx, buffer, name);
|
|
}
|
|
|