Skip to content

problem with different quotes #142

@jean-christophe81

Description

@jean-christophe81

boost 1.87
alma9

When you mix " and ' in a command line unix command line, unix parser and perhaps windows one doesn't take into account the first type of quote.
An example:
with this command line: /bin/sh -c '/bin/echo "ResourceFile AdminPager: " >> /tmp/notif_toto.txt'

It split in
std::vector of length 5, capacity 8 = {"/bin/sh", "-c", "/bin/echo ResourceFile", "AdminPager:", " >> /tmp/notif_toto.txt"}

It should split in:
std::vector of length 3, capacity 8 = {"/bin/sh", "-c", "/bin/echo "ResourceFile AdminPager:" >> /tmp/notif_toto.txt"}

An example of implementation: centreon collect

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions