I noticed that pgwin32_unsetenv() in src/port/win32env.c lacks the input 
validation that its sibling function pgwin32_setenv() has (lines 126-132).
Without these checks, the function will crash on NULL input via 
strlen(NULL), and will accept empty strings or strings containing '=' in 
violation of POSIX.1-2008.
The attached patch adds the same validation that pgwin32_setenv already 
does, making the two functions consistent.  This is purely defensive - 
it only affects callers passing invalid arguments.
regards,
Bryan Green