Zandronum Chat on our Discord Server Get the latest version: 3.2
Source Code

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0003497Doomseeker[All Projects] Bugpublic2018-09-18 21:322018-10-06 18:19
ReporterWubTheCaptain 
Assigned ToWubTheCaptain 
PrioritynormalSeverityminorReproducibilityalways
StatusclosedResolutionfixed 
Platformamd64OSOpenBSDOS Version6.4-current
Product Version1.2 
Target Version1.2Fixed in Version1.2 
Summary0003497: updaterevision: Printing HG_REVISION_NUMBER uses incorrect typedef formatting for hgdate
Description
[  0%] Building C object tools/updaterevision/CMakeFiles/updaterevision.dir/updaterevision.c.o

/home/doomseeker/.local/src/doomseeker/tools/updaterevision/updaterevision.c:161:56: warning: 
      format specifies type 'unsigned long' but the argument has type 'time_t'
      (aka 'long long') [-Wformat]
                fprintf (stream, "#define HG_REVISION_NUMBER %lu\n", hgdate);
                                                             ~~~     ^~~~~~
                                                             %lld
1 warning generated.
Steps To Reproducecmake and gmake the source with appropriate packages installed. Clang 6.0.0.
Additional InformationIntroduced into code with ticket 0003386, commit eb2a08c6a03d23ab9aca8c894dd115dbbe60d7d2.
Attached Filespatch file icon 0001-updaterevision-Fix-HG_REVISION_NUMBER-format-type.patch [^] (1,026 bytes) 2018-09-18 21:40 [Show Content]
patch file icon 0001-updaterevision-Fix-hgdate-data-type-to-signed-64-bit-int.patch [^] (999 bytes) 2018-09-21 15:00 [Show Content]

- Relationships
related to 0003386closedBlzut3 updaterevision: gcc compiler warns of tempnam usage, recommends mkstemp 

-  Notes
User avatar (0019548)
WubTheCaptain (reporter)
2018-09-18 21:41

Patch by me, attached. Tested on GNU/Linux.
User avatar (0019585)
Zalewa (developer)
2018-09-20 17:00

Perhaps to ensure that time_t type fits %lld, it also should be cast to (long long) in that printf() statement?
User avatar (0019597)
WubTheCaptain (reporter)
2018-09-21 15:00

Good idea Zalewa. 0001-updaterevision-Fix-hgdate-data-type-to-signed-64-bit-int.patch
User avatar (0019599)
Zalewa (developer)
2018-09-21 17:21
edited on: 2018-09-21 17:21

Merged your patch:'https://bitbucket.org/Doomseeker/doomseeker/commits/c9c0b4dfe5db98a4a64c8239fd5a3ada431b1eb2 [^]'

Feel free to resolve this ticket at your leisure.

User avatar (0019603)
WubTheCaptain (reporter)
2018-09-22 01:05

Needs testing on OpenBSD.
User avatar (0019608)
WubTheCaptain (reporter)
2018-09-22 01:29

All good on both Debian GNU/Linux and OpenBSD. An unrelated strcpy() issue has ticket 0003498.

Issue Community Support
This issue is already marked as resolved.
If you feel that is not the case, please reopen it and explain why.
Supporters: No one explicitly supports this issue yet.
Opponents: No one explicitly opposes this issue yet.

- Issue History
Date Modified Username Field Change
2018-09-18 21:32 WubTheCaptain New Issue
2018-09-18 21:33 WubTheCaptain Assigned To => WubTheCaptain
2018-09-18 21:33 WubTheCaptain Status new => assigned
2018-09-18 21:40 WubTheCaptain File Added: 0001-updaterevision-Fix-HG_REVISION_NUMBER-format-type.patch
2018-09-18 21:40 WubTheCaptain Status assigned => needs review
2018-09-18 21:41 WubTheCaptain Note Added: 0019548
2018-09-18 21:42 WubTheCaptain Product Version => 1.2
2018-09-18 21:45 WubTheCaptain Additional Information Updated View Revisions
2018-09-18 21:45 WubTheCaptain Relationship added related to 0003386
2018-09-20 17:00 Zalewa Note Added: 0019585
2018-09-21 14:52 WubTheCaptain Status needs review => assigned
2018-09-21 15:00 WubTheCaptain File Added: 0001-updaterevision-Fix-hgdate-data-type-to-signed-64-bit-int.patch
2018-09-21 15:00 WubTheCaptain Note Added: 0019597
2018-09-21 15:00 WubTheCaptain Status assigned => needs review
2018-09-21 17:21 Zalewa Note Added: 0019599
2018-09-21 17:21 Zalewa Note Edited: 0019599 View Revisions
2018-09-22 01:05 WubTheCaptain Note Added: 0019603
2018-09-22 01:05 WubTheCaptain Status needs review => needs testing
2018-09-22 01:24 WubTheCaptain Target Version => 1.2
2018-09-22 01:29 WubTheCaptain Note Added: 0019608
2018-09-22 01:29 WubTheCaptain Status needs testing => resolved
2018-09-22 01:29 WubTheCaptain Fixed in Version => 1.2
2018-09-22 01:29 WubTheCaptain Resolution open => fixed
2018-10-06 18:19 WubTheCaptain Status resolved => closed






Questions or other issues? Contact Us.

Links


Copyright © 2000 - 2025 MantisBT Team
Powered by Mantis Bugtracker