Writing a file out of order

I have a client application that is sending a file in small chunks to the server. There's no guarantee that they'll get there in the right order. I was wonder if there's any way that I could move the file pointer around and write them out of order. Thanks,
Dave Johansen

Actually, you can seek past EOF. When you write the next byte, the file size will be increased as appropriate.
- K
A RandomAccessFile will do this but you have to make
sure the file is initially big enough to hold the
inbound data. You can't seek father than the EOF.

Similar Messages

  • Audiobook files out of order

    Hi,
    I have spent probably three hours on this help site, first figuring out how to classify an audiobook I burned as such on my iPod (which I did), but now the files are out of order - it starts with Chapter 23 then goes to Chapter 9, Chapter 14 and so on. I have tried EVERYTHING and read all relevant posts I can find on this site. It's driving me nuts.
    I have re-numbered the tracks/disks by hand and tried having the "part of a compilation" box checked and unchecked. I sort it in iTunes by Album order, but on my iPod it's all messed up. My iPod is not on shuffle. I have re-set my iPod and my computer.
    I cannot believe it is so difficult to get an Audiobook into iTunes and then onto your iPod. Why does Apple make it so difficult? I've already wasted so much time and really hope there is somebody out there with the heart to help me. : ) Sorry for complaining - but it's frustrating!
    Thanks!

    Kristy: I have no experience of audio books...hoever logic tells me to try this.
    Create a new playlist and drag the chapters to the playlist in the order that you want to listen to them. Then update your iPod.

  • Files out of order in Camera RAW

    When I try to load a batch of .tif files into photoshop Camera RAW, they end up being all out of order numerically when in Cam RAW. How can this be resolved?

    I think the only chance you have to keep your manual order, is to use Bridge, put the images on the order you want them to be opened, and select not the 'Open' neither 'Open with'. Select 'Open In Cameraraw'

  • One File Out of Order in List View

    Okay, this is driving me insane - it's probably something simple that I'm overlooking, but I just can't figure it out. I imported a 17 disc audio book to put on my mother's iPod for her, and for some reason one of the book's subfolders w/i the iTunes music folder is out of order when sorted by file name in list view in the Finder, as can be seen here:
    http://img.villagephotos.com/p/2002-9/54100/FileListPic.jpg
    When first imported, the default names of all the files began with "Don_T", except the problem one (Disc 14), which formatted itself more correctly as "Don't". Thinking that this might be causing the "disorder", I changed all the rest to "Don't" as well, but no dice - Disc 14 refused to move from b/w Discs 6 and 7. I couldn't see any extraneous spaces or strange characters, but to make sure I copied all but the number from the file name of another disc in the set and pasted it into 14's name, but still no change. I even tried fixing my permissions and restarting, just in case, but that didn't help either.
    I'm sure this weirdness won't make a difference when loading the audio book onto the iPod, but it's making me nuts that I can't figure out how to get the stupid thing to move!
    Any help to prevent my imminent cranial explosion would be much appreciated!
    (Possibly) Relevant Info: G4 iMac running 10.3.9, iTunes library lives on an external FW drive, all discs imported w/ iTunes 6.0.2 as 128kbps MP3s
    G4 iMac   Mac OS X (10.3.9)  
    G4 iMac   Mac OS X (10.3.9)  
    G4 iMac   Mac OS X (10.3.9)  

    Rename the file without using copy/paste.....using the keyboard only.
    george

  • Added folder..files out of order

    Adding folder with all files correctly sorted by name, results in out of order sort into itunes library...shuffle is OFF, and most folders import OK.
    Order is important as these are audiobook files.The listing can start with "Lecture 9" and then list in no logical order. As there are up to 200 files,manual rearanging is not on.

    I had the exact same problem with audiobook tracks that did not have disk number tags (which you can see on iTunes). The files under Windows are not in the order they appear in Explorer - the display is sorted by file name (or whatever order you chose) but this does not reflect their physical order. Same with iTunes. You can sort the display, but if you did not have the disk number (and track number), then you will not get the book tracks in the right order. If you look at the actual iTunes files where they are stored, you will see that the file names are preceded by a number (such as "02 filename.m4a") and the number preceding it, I think, is iTune's best guess as to its disk number and it names the files as it imports them.
    If your track files do not have a disk number and/or track number, you can get the trial version of a software called Tag and Rename by Softpointer Inc. (google it) and it will allow you to insert this information. You will then have to delete the old version from iTunes, reimport it, and then copy it back onto iPod.
    By they way, if you ripped your audiobooks using a bitrate that is too low (not unusual for audiobooks), then you might have problems when you pause or turn off during playback and then come back later. You may have to reset your ipod in order for it to turn on. I think the lower bitrate causes the iPod to lose its cookies when trying to save the resume point and crash. So, try to rip using a bitrate that is higher than say 50.
    Good luck. I've had many hours of fun trying to figure out how audiobooks work on iPods.

  • Video files out of order

    I recently updated my iPod classic to version 1.0.3. I notice that the video files are no longer in alphabetical order. Can this be changed back?

    You could throw the iPod classic at a speeding MAC truck and try to replace it where you bought it on Warranty?!
    Or, you could use 'Atomic Parsley' to change the release dates so they're in order.
    You see, the new version changed it so TV shows are listed by release date (like they are on other iPod devices). So TV shows you've ripped/downloaded/added yourself that aren't from the iTunes store probably have "Unknown Release Date" underneath them. If you enter the release dates, or fake ones, they'll be in order.

  • Purchased files out of order, converted

    After I upgraded to v. 7, the total amount of space taken up on my iPod decreased about 13 gigs, and it seems that my mp3s were converted at .aacs. Also, I have a folder with miscellaneous singles, and now the purchased songs are arranged first, not alphabetically as they had been on the older version.
    This is my second post on this issue, so I'm crossing my fingers...

    Anyone know where I can get some actual help on this? Anyone? As if it wasn't enough that my battery only lasts 20 minutes...

  • Binary search tree - writing to a file in alphabetic order words from tree

    Hi
    I have written a program that will read a list of words from a file, insert these into a binary search tree, write words from the tree to another file, so that the resulting list contains words in ascending order. My input file Alpha1.txt contains the following contents in the order and format given (one word per line):
    Dawn
    Dave
    Mike
    Beth     
    David
    Gina
    Pat
    Cindy
    Sue
    My program is supposed to be producing an alphabetical list of these words in another file "final.txt".
    Instead it gives me the following list:
    Dave Beth David Gina Cindy Sue Pat Mike Dawn
    This is obviously wrong, right? My correct list in "final.txt" should be
    Beth Cindy Dave David Dawn Gina Mike Pat Sue
    I am not sure what is wrong with my code which I reproduce below:
    import java.io.*;
    import java.util.*;
    //read Java Developer's Almanac from exampledepot.com
    //Read this: http://en.wikipedia.org/wiki/Tree_traversal
    /**preorder(node)
      print node.value
      if node.left  ? null then preorder(node.left)
      if node.right ? null then preorder(node.right)
    public class AlphabeticBinarySortTree
         private static TreeNode root;
         private static TreeNode runner;
         static String[] alphaArray;
         static int alphaCounter;
         private static TreeNode alphaRunner;
         //Inner class
              private static class TreeNode
                   String word;
                   TreeNode left;
                   TreeNode right;
                   int count;
                   public TreeNode(String word)
                        this.word = word;
                        left = null;
                        right = null;
                   public void insertAll(TreeNode newNode)
                        if(newNode.word.compareTo(runner.word) < 1)
                             System.out.println("newNode.word = " + newNode.word);
                             if(runner.left == null)
                                  runner.left = newNode;
                                  runner = runner.left;
                             else
                                  insertAll(newNode);
                        else if(newNode.word.compareTo(runner.word) > 1)
                             System.out.println("newNode.word = " + newNode.word);
                             if(runner.right == null)
                                  runner.right = newNode;
                                  runner = runner.right;
                             else
                                  insertAll(newNode);
                        else
                             count++;
                   }// end method insertAll
                   // Recursively print words (with counts) in sorted order
                     public static void printInPreOrder(TreeNode root)
                             System.out.println(root.word + " ");
                             if(root.left != null)
                                   printInPreOrder(root.left);
                              if(root.right != null)
                                   printInPreOrder(root.right);
                       } //end method printInPreOrder()
                     //called from inside main
                    public static void arrangeInAscendingOrder(TreeNode root, PrintWriter pWriter)
                             if(root.left != null)
                                   arrangeInAscendingOrder(root.left, pWriter);
                             System.out.println();
                             System.out.println();
                             System.out.println(root.word + " ");
                             pWriter.write(root.word + " ");
                             if(root.right != null)
                                  arrangeInAscendingOrder(root.right, pWriter);
              }//end inner class TreeNode
         public AlphabeticBinarySortTree()
              root = null;
         //belong to the outer class
         public static void main(String[] args)
              System.out.println("This program reads text from a file that it will parse. ");
              System.out.println("In doing so, it will eliminate duplicate strings and ");
              System.out.println("pick up only unique strings.These strings will be in a ");
              System.out.println("stored in alphabetical order in a binary Search tree before they are ");
              System.out.println("written out to another text file in alphabetic order");
              //open the file for reading
              try
                   BufferedReader bReader = new BufferedReader(new FileReader("Alpha1.txt"));
                   String words;
                   int count;
                   //System.out.println("A test to inspect the contents of words: " + words);
                   //System.out.println("Words =" + words);
                   count = 0;
                   //why is there an endless loop when
                   //I use "while(str != null)
                   StringTokenizer st;
                   st = null;
                   //based on http://www.exampledepot.com/egs/java.io/ReadLinesFromFile.html
                   while ((words = bReader.readLine()) != null)
                        st = new StringTokenizer(words);
                       while(st.hasMoreTokens())
                            //shiffman.net/teaching/a2z/concordance
                            String token = st.nextToken();
                            System.out.println("Token = " +token);
                            AlphabeticBinarySortTree.initiateInsert(token);
                            //count the number of tokens in the string
                            count++;
                        }//end inner while
                   }//end outer while
                   System.out.println("Here are the contents of your tree:");
                   //System.out.println("before the call to print()");
                   print();
                   System.out.println("the no of words in the file is: " + count);
                   bReader.close();
              }//end of try
              catch(IOException exception)
                   exception.printStackTrace();
                   /**try
                             FileWriter fWriter = new FileWriter("final.txt");
                             BufferedWriter bWriter = new BufferedWriter(fWriter);
                             PrintWriter pWriter = new PrintWriter(bWriter);
                   catch(IOExcepion exception)
                        exception.printStackTrace();
         } // end main here
         //this method belongs to the outer class
         static void initiateInsert(String word)
              //TreeNode is also static by the way
              TreeNode newNode = new TreeNode(word);
              if(root == null)
                   root = newNode;
                   System.out.println("root.word = " + root.word);
                   runner = root;
              else
                   runner.insertAll(newNode);
         // Start the recursive traversing of the tree
            //without the access specifier 'static'
            //I would get the following error message
            //AlphabeticBinarySortTree.java:119: non-static method print() cannot be referenced from a static context
            public static void print()
                //System.out.println("**********AM I INSIDE THE PRINT() METHOD? ********");
               if (root != null)
                    //System.out.println("++++++++ AM I INSIDE THE IF BLOCK OF THE PRINT() METHOD? +++++++");
                    //System.out.println("Inside THE IF BLOCK OF print() BUT BEFORE THE CALL TO printInPreOrder(),root.word = " + root.word);
                  AlphabeticBinarySortTree.TreeNode.printInPreOrder(root);
                  //open the file for writing
                              try
                                             FileWriter fWriter = new FileWriter("final.txt");
                                             BufferedWriter bWriter = new BufferedWriter(fWriter);
                                             PrintWriter pWriter = new PrintWriter(bWriter);
                                             AlphabeticBinarySortTree.TreeNode.arrangeInAscendingOrder(root, pWriter);
                                          pWriter.close();
                              catch(IOException eException)
                                   eException.printStackTrace();
               }//end of if block
            } // end of method print
    }//end outer enclosing class here--------
    All help is highly appreciated. Thanks for your time and consideration.

    You suggest that I do away with the inner class
    then?Absolutely. In fact I strongly suggest this. You are learning how to code and need to do things cleanly and in small steps. That means first creating your Node class and making sure it works. Then creating your Tree class, and making sure it works. In fact I would load the Strings into the Tree class first directly and testing things before even thinking about reading to and from files. Only then should you implement the file input and output steps.
    The key here is that you don't go on to the next step until you're reasonably sure that your current code works. Remember, it's MUCH easier to code than to debug.

  • Out-of-order-writing and fsync issues ...

    I am facing a fairly interesting problem on my Sun box.
    The problem is: My customer has reported that PostgreSQL loses a file on TRUNCATE.
    The scenario is:
    BEGIN;
    TRUNCATE table;
    COMMIT;
    When the system is killed during this transaction it can happen that the system tables will still see the table while the file on disk is already killed.
    However, this is impossible because the table is actually killed by PostgreSQL AFTER the COMMIT.
    Internally it does:
    BEGIN;
    modify system tables;
    COMMIT (including fsync)
    remove table on disk.
    The problem now is: How than this happen? The only thing which comes to my mind is that the I/O system is doing out-of-order writing. My second theory is that fsync is doing something terribly wrong. More evidence: This happens not too frequently and ONLY on Solaris (We have tested that).
    Can anybody provide me information about the I/O behaviour of the kernel respektively information about what fsync might do wrong?
    Help is very much appreciated.
    Best regards,
    Hans

    Hi there! @BlueSkies84 thanks for posting your concerns. I’m sorry to hear about all the problems with your phone.
    Since we are looking at multiple issues that cannot be controlled via the phone settings, I’d recommend you back your phone up and perform a factory reset. For steps on this please visit us at www.att.com/devicehowto/ and select the make and model of your phone. On the left column you’ll find steps to back up the phone under backup and restore and reset steps under troubleshooting and reset device.
    Hope this helps!
    Charise

  • Automator - When using the Render PDF as Image action, the first file is out of order (naming).  How can I fix this?

    I am creating an Automator Action to render PDF files as Images.  When the PDF is multiple pages, the first page has no numbers, so it ends up at the end of the list.  Here's an example:
    When it is a single page, the result is:
    filename.png
    When it is multiple pages, the result is:
    filename 141.png
    filename 142.png
    filename 143.png
    filename 144.png
    filename.png
    First, it always seems to start at 141...not sure why.
    Second, I did try to add an action to rename and make sequential, however the resulting list was in the same order... except with additional numbers at the end.
    Any suggestions?

    I see. 
    This worked when I tested on 1 PDF:
    The Run Shell Script Action is:
    basename=${1##*/}
    echo ${basename%.*}
    If it's still out of order, add: Sort Finder Items [by creation date] after Render PDF Pages as Images

  • Out of memory error when writing large file

    I have the piece of code below which works fine for writing small files, but when it encounters much larger files (>80M), the jvm throws an out of memory error.
    I believe it has something to do with the Stream classes. If I were to replace my PrintStream reference with the System.out object (which is commented out below), then it runs fine.
    Anyone else encountered this before?
         print = new PrintStream(new FileOutputStream(new File(a_persistDir, getCacheFilename()),
                                                                false));
    //      print = System.out;
              for(Iterator strings = m_lookupTable.keySet().iterator(); strings.hasNext(); ) {
                   StringBuffer sb = new StringBuffer();
                   String string = (String) strings.next();
                   String id = string;
                   sb.append(string).append(KEY_VALUE_SEPARATOR);
                   Collection ids = (Collection) m_lookupTable.get(id);
                   for(Iterator idsIter = ids.iterator(); idsIter.hasNext();) {
                        IBlockingResult blockingResult = (IBlockingResult) idsIter.next();
                        sb.append(blockingResult.getId()).append(VALUE_SEPARATOR);
                   print.println(sb.toString());
                   print.flush();
    } catch (IOException e) {
    } finally {
         if( print != null )
              print.close();
    }

    Yes, my first code would just print the strings as I got them. But it was running out of memory then as well. I thought of constructing a StringBuffer first because I was afraid that the PrintStream wasn't allocating the memory correctly.
    I've also tried flushing the PrintStream after every line is written but I still run into trouble.

  • Out of Order Audiobook files

    Hello All,
    Just got my new iPod today. Upgraded from a iPod mini 4g t the new 30g. I am going to mainly use it for some Podcasts and audiobooks while I work.
    As I was waiting to get my new iPod I downloaded some of my cd audio books into my library and some of the tracks are out of order. How, in my library do I put them back in order?
    When I downloaded them into the library I copied them into a folder, in which they are in order, but as I said they are not in order in my library.
    HELP ME PLEASE! =-(

    Atleast what I do for my Audiobooks is I label the disc number(or book as disc) and also the track number.
    You can do this by right clicking on a song then selecting Get Info and you can add in a Disc number and Track number.
    This can be a slightly long process trust me, I've done all the harry potter audiobooks and Lord Of the Rings unabridged + The Hobbit this way.

  • Error in writing to file encountered while applying patch 9.2.0.8

    Hi,
    I encountered the error message below while applying Oracle 9.2.0.8 patch set using OUI on server running Oracle 9.2.0.7 and Windows 2003 Enterprise Edition SP2:
    Error in writing to file 'C:\oracle\ora92\BIN\orapls9.dll'
    [C:\oracle\ora92\BIN\orapls9.dll (he process cannot access
    the file because it is being used by another process)]
    I've already stopped the Oracle instance and services before invoking the setup.exe.
    My question is: Why this is happening and what is the resolution to prevent this error from happening?

    I used the script in the Metalink note 454040.1 and chose 5. I typed in the orapls9.dll to see which module is locking this dll and I found out it is avrrepsvc.exe which is one of the services our application is running. I just stopped it in Services Console and run the setup.exe of the patch. The installaton of patch run successfully. I checked the version using 'select banner from v$version' and I now got this results:
    SQL> select banner from v$version;
    BANNER
    Oracle9i Enterprise Edition Release 9.2.0.8.0 - Production
    PL/SQL Release 9.2.0.8.0 - Production
    CORE     9.2.0.8.0     Production
    TNS for 32-bit Windows: Version 9.2.0.8.0 - Production
    NLSRTL Version 9.2.0.8.0 - Production
    I have a related question. When checking from dba_registry, isn't it that versions of components should have been upgraded too? Please see below I what got:
    SQL>SELECT SUBSTR(comp_id,1,15) comp_id, status, SUBSTR(version,1,10)
    version, SUBSTR(comp_name,1,30) comp_name
    FROM dba_registry ORDER BY 1;
    COMP_ID STATUS VERSION COMP_NAME
    CATALOG VALID 9.2.0.7.0 Oracle9i Catalog Views
    CATJAVA VALID 9.2.0.7.0 Oracle9i Java Packages
    CATPROC VALID 9.2.0.7.0 Oracle9i Packages and Types
    CONTEXT VALID 9.2.0.7.0 Oracle Text
    JAVAVM VALID 9.2.0.7.0 JServer JAVA Virtual Machine
    ORDIM VALID 9.2.0.7.0 Oracle interMedia
    OWM VALID 9.2.0.1.0 Oracle Workspace Manager
    SDO VALID 9.2.0.7.0 Spatial
    XDB VALID 9.2.0.7.0 Oracle XML Database
    XML VALID 9.2.0.9.0 Oracle XDK for Java
    10 rows selected.
    What tasks did I missed int the steps?
    ADDITION:
    It looks like I forgot to run the catpatch.sql and utlrp.sql.
    Edited by: user5470917 on Jun 19, 2009 2:52 PM

  • I have an iMac mid 2010. After Disk utilities said the drive was corrupt, I ran the hardware test (extended) 3 times. No problems. I than ran Disk utility again and got 2 messages in red-keys out of order, and --Volume corrupt, can't be repaired.  I tried

    I have an iMac mid 2010. After Disk utilities said the drive was corrupt, I ran the hardware test (extended) 3 times. No problems. I than ran Disk utility again and got 2 messages in red…keys out of order, and ……Volume corrupt, can't be repaired.
    I tried to do a system install, but message said…disk can't be changed. Will a complete erase and install fix this ?
    Everything is backed-up.

    There's hardware and software.
    Your drive could physically be in good condition but something has caused the file structure to be messed up (it just happens sometimes).  The directory that keep track of files is corrupt.  Disk Utility can help determine if that is the issue.  In some cases it can repair the problem but it cannot do it to a drive that is being used to boot the system while you are doing that.  You have to boot from another drive.  Some things DU cannot repair and you need to try a stronger utility such as Diskwarrior.
    A failing hard drive (one with mechanical issues) can be a cause of file structure issues but this is by no means always the case.  Apart from looking at the SMART diagnosis feature of Disk Utility (and smart isn't totally reliable) there often isn't a way to tell if a drive is failing until it suddenly happens, which is why you need to maintain backups.
    In your situation it does sound serious and not just minor directory corruption.  You can try erasing (formatting) the drive,  You may need to do this if it is really corrupt, in which case there could be underlying physical issues.  I use old technology but if you have the patience you can try erasing the drive with the security option of writing zeros once (don't do more unless you are going on a 3 week vacation).  This makes the drive not simply assume everything is okay by forcing it try every part of the drive by writing data.  If something is gong wrong you may find it marks a lot of bad sectors, or flat out refuses to format.  Then you know you need a new drive.

  • Macintosh HD can't be mounted, keys out of order and repairing can't be completed

    Hi,
    English isn't my mother tongue so I'll make my best to be understood.
    I have a Macbook Pro from 2012, running on Yosemite (latest version). I installed Onyx which told me my disk needed to be verified and repaired. Following this advice, I restarted my computer with Disk Utility and completed a verifying and repairing. Which led to a terrible outcome. Since then, everytime I boot with my user on my Mac, my computer shuts down in the middle of the progress bar. I tried to find an explanation to it and fix it, so I tried the following things:
    1) I booted with CMD + R to go into Disk Utility
    2) I runned a verify Disk on "Macintosh HD" Core Storage Logical Volume Disk, which didn't give me any error
    3) I unlocked "Macintosh HD" Mounted encrypted partition and runned a verify disk, which says :
    "Keys out of order
    The volume Macintosh HD was found corrupt and needs to be repaired.
    File system check exit code is 8.
    Error : the disk needs to be repaired, Repair disk."
    4) Unfortunately, the "repair disk" button is grayed.
    5) So I runned repair Disk on  "Macintosh HD" Core Storage Logical Volume Disk, which didn't give me any error.
    6) I tried to boot my computer again but it still shuts down when trying to open my user.
    7) Did all the same process again, but now the error is "Keys length incorrect" and repairing is now always blocked in the middle of the progress bar.
    Is there any way I could extract the data I care about (photos, etc.) before erasing the disk or buying a new one?

    There's hardware and software.
    Your drive could physically be in good condition but something has caused the file structure to be messed up (it just happens sometimes).  The directory that keep track of files is corrupt.  Disk Utility can help determine if that is the issue.  In some cases it can repair the problem but it cannot do it to a drive that is being used to boot the system while you are doing that.  You have to boot from another drive.  Some things DU cannot repair and you need to try a stronger utility such as Diskwarrior.
    A failing hard drive (one with mechanical issues) can be a cause of file structure issues but this is by no means always the case.  Apart from looking at the SMART diagnosis feature of Disk Utility (and smart isn't totally reliable) there often isn't a way to tell if a drive is failing until it suddenly happens, which is why you need to maintain backups.
    In your situation it does sound serious and not just minor directory corruption.  You can try erasing (formatting) the drive,  You may need to do this if it is really corrupt, in which case there could be underlying physical issues.  I use old technology but if you have the patience you can try erasing the drive with the security option of writing zeros once (don't do more unless you are going on a 3 week vacation).  This makes the drive not simply assume everything is okay by forcing it try every part of the drive by writing data.  If something is gong wrong you may find it marks a lot of bad sectors, or flat out refuses to format.  Then you know you need a new drive.

Maybe you are looking for

  • Mobile Account Sync Problem on Server

    I am using home folder syncing on a network with an iMac and a MacBook Pro. The iMac is the Open Directory server where the network user home folders are stored, and is also a workstation used by the network users. Does anyone know how to avoid this?

  • External Hard Drive Won't Mount in 10.2.8

    Greetings, I have a MacBook Pro running the latest version of Tiger. I have a Maxtor 300 GB external hard drive (Mac OS Extended [journaled] ) which I use with my MacBook to store music, video, other media, and backups. I connect that drive to my Mac

  • Display Images at WD ABAP application

    Hi, How to display the image which exist in KM ? I need to read the image from KM and display in WebDynpro ABAP  application. How to do it.  Do we have that provision here ? If not posible can we display some images keeping them in the application it

  • How do I find my photos on my external hard drive backed up using Time Machine?

    How do I find my photos on my external hard drive backed up using Time Machine? My hard drive died so this is my only storage. The hard drive was from an early 2008 Macbook Pro. I had recently installed Snow Leopard.

  • No audio/visual on TV show downloaded from iTunes app on iPod touch

    I downloaded a $3.99 Avatar TV episode from the iTunes app on my 2nd gen iPod touch, and it seemed to go smoothly until I tried playing the episode. It appears to be playing but all I see is black and there is no audio. I restarted my iPod twice; sti