Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • openfoam openfoam
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 421
    • Issues 421
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 7
    • Merge requests 7
  • Deployments
    • Deployments
    • Releases
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • Development
  • openfoamopenfoam
  • Issues
  • #2165
Closed
Open
Issue created Jul 22, 2021 by Oliver Oxtoby@oliveroxtoby

gmshToFoam failure

Summary

gmshToFoam is unable to convert the example meshes in the source tree. This worked fine in v2012.

Steps to reproduce

Run Allrun in the attached minimal example. This is a example mesh from the source tree.

Example case

gmshToFoamBug.tgz

What is the current bug behaviour?

gmshToFoam exits with the error:

Wrong token type - expected word, found on line 0: variable "$MeshFormat"

file: input at line 0.

    From Foam::Istream& Foam::operator>>(Foam::Istream&, Foam::word&)
    in file primitives/strings/word/wordIO.C at line 70.

FOAM exiting

What is the expected correct behavior?

(No error)

Environment information

  • OpenFOAM version : v2106
  • Operating system : ubuntu
  • Hardware info :
  • Compiler : (OpenCFD binary package)

Possible fixes

In gmshToFoam.C, replacing all occurrences of word tag(lineStr); with string tag(token(tagStr).stringToken()); seems to do the trick.

Assignee
Assign to
Time tracking