[partitionmanager] [Bug 447961] KDE Partition Manager deletes davfs entry from /etc/fstab

2022-01-05 Thread Andrius Štikonas
https://bugs.kde.org/show_bug.cgi?id=447961

Andrius Štikonas  changed:

   What|Removed |Added

   Version Fixed In||22.04.0

-- 
You are receiving this mail because:
You are watching all bug changes.

[partitionmanager] [Bug 447961] KDE Partition Manager deletes davfs entry from /etc/fstab

2022-01-05 Thread Andrius Štikonas
https://bugs.kde.org/show_bug.cgi?id=447961

Andrius Štikonas  changed:

   What|Removed |Added

 Resolution|--- |FIXED
 Status|CONFIRMED   |RESOLVED
  Latest Commit||https://invent.kde.org/syst
   ||em/kpmcore/commit/5ffc5c6f2
   ||38c70735637035456a9484f4f0f
   ||41dd

--- Comment #9 from Andrius Štikonas  ---
Git commit 5ffc5c6f238c70735637035456a9484f4f0f41dd by Andrius Štikonas.
Committed on 05/01/2022 at 23:00.
Pushed by stikonas into branch 'master'.

Fix davfs entries being omitted from fstab file.

M  +4-2src/core/fstab.cpp
M  +1-1src/core/fstab.h

https://invent.kde.org/system/kpmcore/commit/5ffc5c6f238c70735637035456a9484f4f0f41dd

-- 
You are receiving this mail because:
You are watching all bug changes.

[partitionmanager] [Bug 447961] KDE Partition Manager deletes davfs entry from /etc/fstab

2022-01-05 Thread Andrius Štikonas
https://bugs.kde.org/show_bug.cgi?id=447961

--- Comment #8 from Andrius Štikonas  ---
(In reply to Andrius Štikonas from comment #7)
> (In reply to Michael Ehrlichman from comment #6)
> > That sounds right.  As you probably expect, if I prefix the line with
> > "UUID=", then the line is not deleted.
> > 
> > So an addition like the following, or perhaps a check for fsType=='davfs',
> > would work, no? 
> > 
> > } else if (m_fsSpec.startsWith(QStringLiteral("http"))) {
> > m_entryType = FstabEntry::Type::netdev;
> > m_deviceNode = m_fsSpec;
> 
> Hmm, perhaps just setting m_deviceNode = m_fsSpec before all those if/else
> blocks work, let me test.

Actually it looks like things are going wrong during write stage:
https://invent.kde.org/system/kpmcore/-/blob/master/src/core/fstab.cpp#L280

-- 
You are receiving this mail because:
You are watching all bug changes.

[partitionmanager] [Bug 447961] KDE Partition Manager deletes davfs entry from /etc/fstab

2022-01-05 Thread Andrius Štikonas
https://bugs.kde.org/show_bug.cgi?id=447961

--- Comment #7 from Andrius Štikonas  ---
(In reply to Michael Ehrlichman from comment #6)
> That sounds right.  As you probably expect, if I prefix the line with
> "UUID=", then the line is not deleted.
> 
> So an addition like the following, or perhaps a check for fsType=='davfs',
> would work, no? 
> 
> } else if (m_fsSpec.startsWith(QStringLiteral("http"))) {
> m_entryType = FstabEntry::Type::netdev;
> m_deviceNode = m_fsSpec;

Hmm, perhaps just setting m_deviceNode = m_fsSpec before all those if/else
blocks work, let me test.

-- 
You are receiving this mail because:
You are watching all bug changes.

[partitionmanager] [Bug 447961] KDE Partition Manager deletes davfs entry from /etc/fstab

2022-01-05 Thread Michael Ehrlichman
https://bugs.kde.org/show_bug.cgi?id=447961

--- Comment #6 from Michael Ehrlichman  ---
That sounds right.  As you probably expect, if I prefix the line with "UUID=",
then the line is not deleted.

So an addition like the following, or perhaps a check for fsType=='davfs',
would work, no? 

} else if (m_fsSpec.startsWith(QStringLiteral("http"))) {
m_entryType = FstabEntry::Type::netdev;
m_deviceNode = m_fsSpec;

-- 
You are receiving this mail because:
You are watching all bug changes.

[partitionmanager] [Bug 447961] KDE Partition Manager deletes davfs entry from /etc/fstab

2022-01-05 Thread Andrius Štikonas
https://bugs.kde.org/show_bug.cgi?id=447961

Andrius Štikonas  changed:

   What|Removed |Added

 Ever confirmed|0   |1
 Status|REPORTED|CONFIRMED

-- 
You are receiving this mail because:
You are watching all bug changes.

[partitionmanager] [Bug 447961] KDE Partition Manager deletes davfs entry from /etc/fstab

2022-01-05 Thread Andrius Štikonas
https://bugs.kde.org/show_bug.cgi?id=447961

--- Comment #5 from Andrius Štikonas  ---
(In reply to Michael Ehrlichman from comment #4)
> Perhaps a clue:  If I put a "/" at the front of the dafvs line  i.e. 
> replace "https" with "/https" then the bug goes away.
> 
> Of course putting a slash there is not a fix, I am simply trying to find
> clues as to what is wrong with the text processing.

I think that suggest bug in
static void parseFsSpec(const QString& m_fsSpec, FstabEntry::Type& m_entryType,
QString& m_deviceNode)
function. We don't hit any of the "if/else" cases there.

-- 
You are receiving this mail because:
You are watching all bug changes.

[partitionmanager] [Bug 447961] KDE Partition Manager deletes davfs entry from /etc/fstab

2022-01-05 Thread Michael Ehrlichman
https://bugs.kde.org/show_bug.cgi?id=447961

--- Comment #4 from Michael Ehrlichman  ---
Perhaps a clue:  If I put a "/" at the front of the dafvs line  i.e.  replace
"https" with "/https" then the bug goes away.

Of course putting a slash there is not a fix, I am simply trying to find clues
as to what is wrong with the text processing.

-- 
You are receiving this mail because:
You are watching all bug changes.

[partitionmanager] [Bug 447961] KDE Partition Manager deletes davfs entry from /etc/fstab

2022-01-05 Thread Andrius Štikonas
https://bugs.kde.org/show_bug.cgi?id=447961

--- Comment #3 from Andrius Štikonas  ---
(In reply to Michael Ehrlichman from comment #2)
> The davfs entry does not contain # characters.  Here is a less redacted
> fstab entry:
> 
> https://abdc.net/remote.php/webdav/myfolder /home/einstein/myfolder davfs
> _netdev,noexec,nosuid,user,uid=einstein  0 3

Thanks. Hmm right now I don't immediately see what's going wrong here.
I thought # might be tripping in one of these two lines
https://invent.kde.org/system/kpmcore/-/blob/master/src/core/fstab.cpp#L71
https://invent.kde.org/system/kpmcore/-/blob/master/src/core/fstab.cpp#L88

but I guess something else is going on.

-- 
You are receiving this mail because:
You are watching all bug changes.

[partitionmanager] [Bug 447961] KDE Partition Manager deletes davfs entry from /etc/fstab

2022-01-05 Thread Michael Ehrlichman
https://bugs.kde.org/show_bug.cgi?id=447961

--- Comment #2 from Michael Ehrlichman  ---
The davfs entry does not contain # characters.  Here is a less redacted fstab
entry:

https://abdc.net/remote.php/webdav/myfolder /home/einstein/myfolder davfs
_netdev,noexec,nosuid,user,uid=einstein  0 3

-- 
You are receiving this mail because:
You are watching all bug changes.

[partitionmanager] [Bug 447961] KDE Partition Manager deletes davfs entry from /etc/fstab

2022-01-05 Thread Andrius Štikonas
https://bugs.kde.org/show_bug.cgi?id=447961

--- Comment #1 from Andrius Štikonas  ---
Does URL contain any # characters?

-- 
You are receiving this mail because:
You are watching all bug changes.