/* get header */
const char *proxy_auth = aRequest->header.getStr(type);
+ /* if proxy_auth is actually NULL, we'd better not manipulate it. */
+ if (!proxy_auth) {
+ debugs(29, 4, "WARNING: NTLM Authentication missing authorization header");
+ return;
+ }
+
/* locate second word */
const char *blob = proxy_auth;
- /* if proxy_auth is actually NULL, we'd better not manipulate it. */
- if (blob) {
- while (xisspace(*blob) && *blob)
- ++blob;
+ while (xisspace(*blob) && *blob)
+ ++blob;
- while (!xisspace(*blob) && *blob)
- ++blob;
+ while (!xisspace(*blob) && *blob)
+ ++blob;
- while (xisspace(*blob) && *blob)
- ++blob;
- }
+ while (xisspace(*blob) && *blob)
+ ++blob;
switch (user()->credentials()) {