FU Logo
  • Startseite
  • Kontakt
  • Impressum
  • Home
  • Listenauswahl
  • Anleitungen

[linux-minidisc] "netmdcli send" does not break on errors

<-- thread -->
<-- date -->
  • From: Thomas Arp <manner.moe@gmx.de>
  • To: linux-minidisc@lists.fu-berlin.de
  • Date: Fri, 16 Sep 2011 22:34:37 +0200
  • Subject: [linux-minidisc] "netmdcli send" does not break on errors

Hi,
i accidently used a write protected minidisc and a dics with no space left to test netmd download with netmdcli.
The netmdcli send routine does not check if the dics is write prtected or if there is enough space left.
In both cases netmd_secure_send_track(...) fails with "unknown error" but the code doesn´t break.
It tries to set the disc title to the track number from the variable "uint16_t track" which is uninitialized.
In my case trying to set the title for track number 52, but there are only 15 tracks on the disc.
Also it tries to commit a track which is not written.

I think we have to implement some more checking routines before trying to transmit a track:
1. check if disc is write protected
2. calculate the space needed for the track and check if there is enough space left on the disc
3. if netmd_secure_send_track(..) fails, don´t try to set title and commit track, just cleanup/leave secure session and exit

Regards
Thomas

<-- thread -->
<-- date -->
  • Follow-Ups:
    • Re: [linux-minidisc] "netmdcli send" does not break on errors
      • From: Thomas Arp <manner.moe@gmx.de>
  • linux-minidisc - September 2011 - Archives indexes sorted by:
    [ thread ] [ subject ] [ author ] [ date ]
  • Complete archive of the linux-minidisc mailing list
  • More info on this list...

Hilfe

  • FAQ
  • Dienstbeschreibung
  • ZEDAT Beratung
  • postmaster@lists.fu-berlin.de

Service-Navigation

  • Startseite
  • Listenauswahl

Einrichtung Mailingliste

  • ZEDAT-Portal
  • Mailinglisten Portal