Small bug in juce_getInternetFileHeaders


#1

Having trouble compiling on Mac with the latest GIT commit. The mac version of some platform specific code seems to return bool whereas the expected prototype is void. The return value is never used so I just patched it to return void for now. Not sure if you’re aware of this.

[code]Aarons-Mac-mini:juce aarond10$ git diff
diff --git a/juce_amalgamated.cpp b/juce_amalgamated.cpp
index cd9ee73…bdbb2a9 100644
— a/juce_amalgamated.cpp
+++ b/juce_amalgamated.cpp
@@ -261426,7 +261426,7 @@ int64 juce_getInternetFileContentLength (void* handle)
return -1;
}

-bool juce_getInternetFileHeaders (void* handle, StringPairArray& headers)
+void juce_getInternetFileHeaders (void* handle, StringPairArray& headers)
{
JuceURLConnection* const s = (JuceURLConnection*) handle;

@@ -261438,11 +261438,7 @@ bool juce_getInternetFileHeaders (void* handle, StringPairArray& headers)
while ((key = [enumerator nextObject]) != nil)
headers.set (nsStringToJuce (key),
nsStringToJuce ((NSString*) [s->headers objectForKey: key]));

  •           return true;
      }
    
  •   return false;
    

}

int juce_seekInInternetFile (void* handle, int /newPosition/)[/code]


#2

here too.

Also getting compile errors on Mac regarding non resolved symbols for DeletedAtShutdown with this latest tip.
Edit: on windows, too, but this issue only happens when I try to compile the Amalgamator. Other apps work.


#3

Sorry - don’t know how that bool/void thing got in there, I’ll tidy it up.

DeletedAtShutdown actually isn’t available unless you’re building a GUI app… can’t think how it could have got itself included in the amalgamator, but I’ll take a look at that too. Thanks!