Bug 216808 - sysutils/bsdstats: Missing ${CR} in POST for ports
Summary: sysutils/bsdstats: Missing ${CR} in POST for ports
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Many People
Assignee: Carlos J. Puga Medina
URL:
Keywords: patch, patch-ready
Depends on:
Blocks:
 
Reported: 2017-02-05 06:08 UTC by Marc Fournier
Modified: 2017-02-06 10:51 UTC (History)
3 users (show)

See Also:
yuri: maintainer-feedback+


Attachments
Patch for missing ${CR} (1.09 KB, patch)
2017-02-05 06:42 UTC, Marc Fournier
yuri: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Marc Fournier 2017-02-05 06:08:49 UTC
There is a missing ${CR} after the 'Connection: close' line that breaks posting ports to the server ... the following patch corrects it ...


# diff -cr /tmp/300.statistics 300.statistics
*** /tmp/300.statistics	Sat Feb  4 08:07:42 2017
--- 300.statistics	Sat Feb  4 08:09:20 2017
***************
*** 159,165 ****
   if [ -n "${http_header_proxy_auth}" ]; then txt="${txt}${CR}${NL}Proxy-Authorization: ${http_header_proxy_auth}"; fi
   txt="${txt}${CR}${NL}User-Agent: bsdstats-${CURR_VERSION}"
   txt="${txt}${CR}${NL}Connection: close"
!   if [ -n "${content_type}" ]; then txt="${txt}${NL}Content-Type: ${content_type}"; fi
   if [ -n "${body}" ]; then txt="${txt}${CR}${NL}Content-Length: ${#body}"; fi
   txt="${txt}${CR}${NL}${CR}${NL}${body}"

--- 159,165 ----
   if [ -n "${http_header_proxy_auth}" ]; then txt="${txt}${CR}${NL}Proxy-Authorization: ${http_header_proxy_auth}"; fi
   txt="${txt}${CR}${NL}User-Agent: bsdstats-${CURR_VERSION}"
   txt="${txt}${CR}${NL}Connection: close"
!   if [ -n "${content_type}" ]; then txt="${txt}${CR}${NL}Content-Type: ${content_type}"; fi
   if [ -n "${body}" ]; then txt="${txt}${CR}${NL}Content-Length: ${#body}"; fi
   txt="${txt}${CR}${NL}${CR}${NL}${body}”
Comment 1 Yuri Victorovich freebsd_committer freebsd_triage 2017-02-05 06:16:49 UTC
Marc, you need to attach the patch.

> (cd /usr/ports && svn diff sysutils/bsdstats) >> bsdstats.patch
Comment 2 Marc Fournier 2017-02-05 06:42:13 UTC
Created attachment 179625 [details]
Patch for missing ${CR}
Comment 3 Carlos J. Puga Medina freebsd_committer freebsd_triage 2017-02-06 09:32:05 UTC
Take.
Comment 4 Carlos J. Puga Medina freebsd_committer freebsd_triage 2017-02-06 10:10:34 UTC
(In reply to Marc Fournier from comment #2)

Why did you update PORTVERSION to 6.1?
Comment 5 Yuri Victorovich freebsd_committer freebsd_triage 2017-02-06 10:21:00 UTC
PORTREVISION=1 should be set, PORTVERSION shouldn't change.
Comment 6 commit-hook freebsd_committer freebsd_triage 2017-02-06 10:48:32 UTC
A commit references this bug:

Author: cpm
Date: Mon Feb  6 10:48:10 UTC 2017
New revision: 433482
URL: https://svnweb.freebsd.org/changeset/ports/433482

Log:
  - Add missing ${CR} variable in 300.statistics.in
  - Bump PORTREVISION

  PR:		216808
  Submitted by:	Marc Fournier <yscrappy@gmail.com>
  Approved by:	Yuri Victorovich <yuri@rawbw.com> (maintainer)

Changes:
  head/sysutils/bsdstats/Makefile
  head/sysutils/bsdstats/files/300.statistics.in
Comment 7 Carlos J. Puga Medina freebsd_committer freebsd_triage 2017-02-06 10:49:18 UTC
Committed!

Thanks
Comment 8 Marc Fournier 2017-02-06 10:51:26 UTC
Its up to you, but from my perspective, it was a bug fix release for the software itself, not a bug fix for the port ... I thought PORTREVISION was for changes to / fixes for port related stuff (ie. Makefile) ...