Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix bug in URIPath assignment operator #275

Merged
merged 1 commit into from
Dec 6, 2021

Conversation

mjcarroll
Copy link
Contributor

@mjcarroll mjcarroll commented Dec 3, 2021

🦟 Bug fix

Discovered in #274.

Summary

The issue is that the URIPath::Implementation struct has a trailingSlash member: https://github.com/ignitionrobotics/ign-common/blob/ign-common4/src/URI.cc#L54-L73

The originally written copy-assignment operator doesn't copy this member:
https://github.com/ignitionrobotics/ign-common/blob/ign-common4/src/URI.cc#L586-L591

And the test exercises this copy-assignment:
https://github.com/ignitionrobotics/ign-common/blob/ign-common4/src/URI_TEST.cc#L890-L894

In this case, ImplPtr has shown that the previous behavior is actually a bug, and we should fix it in previous versions.

Note to maintainers: Remember to use Squash-Merge

@github-actions github-actions bot added 🌱 garden Ignition Garden 🏢 edifice Ignition Edifice 🏯 fortress Ignition Fortress labels Dec 3, 2021
@codecov
Copy link

codecov bot commented Dec 3, 2021

Codecov Report

Merging #275 (3018d03) into ign-common4 (5d84d4a) will increase coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@             Coverage Diff              @@
##           ign-common4     #275   +/-   ##
============================================
  Coverage        77.10%   77.11%           
============================================
  Files               75       75           
  Lines            10694    10695    +1     
============================================
+ Hits              8246     8247    +1     
  Misses            2448     2448           
Impacted Files Coverage Δ
src/URI.cc 97.41% <100.00%> (+<0.01%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5d84d4a...3018d03. Read the comment docs.

@mjcarroll mjcarroll merged commit f75ad3d into ign-common4 Dec 6, 2021
@mjcarroll mjcarroll deleted the bug/uri_path_assignment branch December 6, 2021 15:48
@chapulina chapulina mentioned this pull request Jan 12, 2022
7 tasks
@osrf-triage
Copy link

This pull request has been mentioned on Gazebo Community. There might be relevant details there:

https://community.gazebosim.org/t/new-ignition-releases-2022-01-24-citadel-edifice-fortress/1241/1

scpeters added a commit to gazebosim/gz-fuel-tools that referenced this pull request Mar 6, 2022
chapulina pushed a commit to gazebosim/gz-fuel-tools that referenced this pull request Mar 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏢 edifice Ignition Edifice 🏯 fortress Ignition Fortress 🌱 garden Ignition Garden
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants