Project JEDI - Issue Tracker
Mantis Bugtracker

Viewing Issue Simple Details Jump to Notes ] View Advanced ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0005922 [JEDI VCL] 00 JVCL Components tweak always 2012-06-28 15:00 2015-09-21 17:47
Reporter tetardd View Status public  
Assigned To obones
Priority normal Resolution fixed  
Status resolved   Product Version 3.45
Summary 0005922: HTTPStatus in TJvHttpUrlGrabber should be an integer (or DWord)
Description An HTTP status is managed an a DWord by the OS, e.g. the common 404 error. It's easy to see, the error codes are available as integers in WinInet (search for HTTP_STATUS_NOT_FOUND).

It is therefore weird that TJvHttpUrlGrabber.FHTTPStatus is defined as string.

Change the type as Integer/DWord and change the code that gets in:

procedure TJvHttpUrlGrabberThread.Grab;
Var
   ...
   StatusValue : DWord;
Begin
    ...
    dwIndex := 0;
    dwBufLen := SizeOf(StatusValue);
    HttpQueryInfo(hDownload, HTTP_QUERY_STATUS_CODE Or HTTP_Query_Flag_Number, @StatusValue, dwBufLen, dwIndex);
    Grabber.FHTTPStatus := StatusValue;
    ...
End
     
Additional Information
Tags No tags attached.
Attached Files ? file icon JvUrlGrabbers.pas [^] (40,718 bytes) 2013-01-19 08:34

- Relationships

-  Notes
(0020339)
obones (administrator)
2013-01-15 15:08

What about existing code that uses this? Shouldn't we add a new property that has the appropriate type?
(0020407)
tetardd (reporter)
2013-01-19 08:34

Attached is my proposed changes. These are marked with Tetard for your consideration.

Thanks.
(0020850)
obones (administrator)
2013-12-16 11:57

This is now in GIT

- Issue History
Date Modified Username Field Change
2012-06-28 15:00 tetardd New Issue
2013-01-15 15:08 obones Note Added: 0020339
2013-01-15 15:08 obones Status new => feedback
2013-01-19 08:34 tetardd File Added: JvUrlGrabbers.pas
2013-01-19 08:34 tetardd Note Added: 0020407
2013-12-13 11:41 obones Status feedback => acknowledged
2013-12-16 11:57 obones Note Added: 0020850
2013-12-16 11:57 obones Status acknowledged => resolved
2013-12-16 11:57 obones Fixed in Version => Daily / GIT
2013-12-16 11:57 obones Resolution open => fixed
2013-12-16 11:57 obones Assigned To => obones
2015-09-21 17:47 obones Fixed in Version Daily / GIT => 3.49


Mantis 1.1.6[^]
Copyright © 2000 - 2008 Mantis Group
Powered by Mantis Bugtracker