Skip to content

Commit

Permalink
Util: Use public API from libsdformat for detecting non-file source
Browse files Browse the repository at this point in the history
  • Loading branch information
EricCousineau-TRI committed Apr 29, 2021
1 parent 4e40b36 commit 7005acd
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Util.cc
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
#include <ignition/common/StringUtils.hh>
#include <ignition/common/Util.hh>
#include <ignition/transport/TopicUtils.hh>
#include <sdf/Types.hh>

#include "ignition/gazebo/components/Actor.hh"
#include "ignition/gazebo/components/Collision.hh"
Expand Down Expand Up @@ -286,7 +287,7 @@ std::string asFullPath(const std::string &_uri, const std::string &_filePath)
#endif

// When SDF is loaded from a string instead of a file
if ("data-string" == _filePath)
if (std::string(sdf::kSdfStringSource) == _filePath)
{
ignwarn << "Can't resolve full path for relative path ["
<< _uri << "]. Loaded from a data-string." << std::endl;
Expand Down

0 comments on commit 7005acd

Please sign in to comment.