New Thread() throws NullPointerException, what happens inside ?

In a multi threaded program, the following line causes a NullPointerException:
Thread tt = new Thread();
Only one thread at a time accesses this line. I use 'inner classes', inheritance and many threads. Is there a subtle side effect that causes the exception ?

Ive found out that new Thread() calls new Thread(null, null, gname).
If group is null like in this case, the group is set to be the same ThreadGroup as the thread that is creating the new thread. Unfortunately the thread that is creating the new thread has no ThreadGroup (e.g. is null). How is that possible ?
Thanks for answers.

Similar Messages

  • What happens inside ...... when fired Index Reorganize

    Hi all,
    what happens inside ...... when fired Index Reorganize
    Thanks
    vijay

    Logical scan fragmentation is removed (where possible). This can improve performance of certain queries, because it reduces the amount of big disk head movements need to go through all the pages.
    In addition to that, it brings the amount of unused space in line with the original fill factor of the index. If you haven't specified any fill factor when the index was first created, then all unused space will be removed (where possible). It does this
    by joining the rows of multiple pages onto fewer pages and releasing the empty pages. This can improve performance of many queries, since fewer I/O and less memory is now needed to access the same amount of row data.
    When the command runs, it will lock just one or a few pages at a time. This way, most blocking is avoided, and any blocking that does occur will be short lived.
    This also means that the reorganization occurs inline, within the pages and extents that are already allocated for the specific index. This is one of the big differences with Reindexing, where new pages (and extents) are allocated.
    Gert-Jan

  • I want to change my Apple ID because I have a new email address, but what happens when someone tries to facetime me using my old Apple ID?

    I want to change my Apple ID because I have a new email address, but what happens when someone tries to facetime me using my old Apple ID? Will they still be able to contact me on facetime using my old Apple ID?

    Not if you change the ID.  You would need to give them the new address.

  • HT203477 it says save operation could not be completed when I make a new project... what happened?

    it says save operation could not be completed when I make a new project... what happened?

    This is happening to me as well. No solutions from anyone. When it happens, it does not matter which drive I try to save to ... it won't create a new event or project ANYWHERE. I usually have to reboot.

  • Buying new HDD for laptop - What happens to WIndows? p755-s5269

    Hi all, I am experiencing an unfortunate truth with my laptop.  Windows (and Linux) both got excruciatingly slow yesterday for no reason whatsoever.  Upon booting into Windows it said that my hard disk was going to kick the bucket sometime soon.  So I called customer support and I did all that they told me to do, except buying the Windows Recovery CD.  Firstly, the hard drive is going out, not the software so I was screwed anyway.  So now that I have deleted the linux partitions, and now using a LiveUSB of OpenSUSE, I know I am going to lose Windows.  However, I saw that there are product keys at the bottom of the laptop.
    My question:  What will happen to Windows 7 when my new HDD arrives?  Will I not be able to transfer the OS key to the new hard drive?  I can delete all of the partitions anyway to where I have nothing on the HDD if that will help. 
    Thanks in advanced!

    Presumably it will use updated drivers when it creates the media.
    No, Sally. That partition never changes. You get recovery media that restores the hard disk to its original out-of-the-box contents (including the hidden partition which contains the same old recovery image).
    -Jerry

  • Bootcamp will no longer boot after deleting partition #3 of my new Mac Mini.  What happened?  Was it the way I tried to reclaim the HDD space for Mac?

    Here's my dilemma.  I have a new Mac Mini - a week old.  I installed Windows 7 on it using Mac's Bootcamp assistant.  I then set up and configured my Windows 7 world and everything worked fine.  No issues logging in between Lion or Win7 via the restart/option key procedure.  Well, yesterday I split my Mac HD partition one more time to create a third partition (was created as an "extra", e.g. possible future partition for another operating system).  After creating it, I then decided that I didn't really need it.  So I deleted it in Disk Utility and attempted to drag the Mac HD partition line downward so as to "fill in the gap" and reclaim the lost hardrive space.  It seemed as if I could reclaim about 1 gig or so, but I figured...oh well. 
    Well, the Mac HD partition seems to work just fine, but now I've noticed that I can't get into the Bootcamp partition anymore.  It wont boot.  If I try to verify the partition [doesn't even give me "repair" as an option), then it fails and gives me the following error message: "verify volume failed.  invalid request."  When I go to the Startup Disk option in my System Preferences section, it displays the bootcamp partition as a folder and not as a drive anymore.
    I'm assuming that I messed up some permissions or lost some vital links during my attempted resizing/reclaiming of harddrive space.  How do I fix this without having to reload either all of my Mac info or all or my Win7 info?  I'd hate to consider the last two days of my life loading this crap up a complete loss. 
    Thanks in advance!

    Thanks for checking in, BDAQua.
    Problem solved.
    In the docs that came with my Powerlogix accelerator card, I found this sentence buried:
    "If you reset the PRAM, the NVRAM code for OS9 compatibility is cleared, so you will have to boot from the Firmawre Update CD and perform this process again in order to boot in OS9."
    The "process" it's referring to is the process of setting up the NVRAM for booting into OS9 from the CD.
    Fortunately, I was able to find the disk, and it worked as expected. I can now, once again boot into OS9.
    Conclusion: My (unadvised) attempt to load Leopard on this old machine apparently reset the PRAM on the accelerator card and cleared the NVRAM code for OS9 boot. Although I did attempt to reset the NVRAM via Open Firmware, it did not reset it on the accelerator card.
    So, thank you BDAQua, for your "Ah yes" . . . that's all I needed to steer me in the right direction.
    Gratefully,
    tupester

  • What happen to julius thread in ABAP DEVELOPMENT?

    It was reformatted by the new 5000 characters per post limit
    I am busy working on a solution to split them and move each part to its own respecting sub-development forum - but have not got to it yet. Sorry for being slow.
    The FAQ and memorable discussions thread in the Security Forum is affected as well, but there is only one forum... :-((
    Any creating ideas on how to fix that one (other than removing information from it)?
    Cheers,
    Julius

    Actually it is happening since couple of week. Might be you have found yourself in this situation now.
    Also there are two thread already open on the same. Perhaps you missed them.
    Improper display of threads
    And outstandingly "what happen to julius thread in ABAP DEVELOPMENT?" Nice Subject Line
    Perhaps, It looks [Line of the day|Re: Line of the day!] !!
    P.S. Subject tempered (Or Perhaps corrected)....;-)
    Anyways,
    @ Julius: Since there is 5000 Characters Limit has been introduced for keeping the forum neat, undersized and informative as much as possible rather than long bulky programs.
    But My Question is What about the Programs and Threads which had already been posted in last 5-6 Years of SDN(now SCN)?
    I can see all the previous threads also have been affected!
    So Does SAP having any Programmer In their team of Michael Goeck or David Branan(Who is working from behind the scene ) to introduced the restriction of 5K chars based on Date?!?
    Cheers

  • How to call a sequence in a new thread from C++ dll

    Here is what I am trying to do:
    I implemented a dll that monitors network traffic, and it also supports message handlers that can be triggered when a specific message has been received. Essentially the receipt of a message is like an event causing additional code to be executed. What I need to do is have the message handler in the dll call/execute a sequence (either is the same sequence file that originally called the dll, or in a different sequence file). Also I want the sequence to be executed within the same execution object for the purpose of result collection and report generation. I am expecting the dll to have to launch a new thread to call a sequence because of the asynchronous nature of the message received event.
    There are easier ways to achieve the same result, but one of my goals is to make it easy for a test developer to configure a message handler, by having only one step in their sequence to configure the message handler. I want the rest to be transparent to the user.
    I am unsure about how to implement this feature, so I am asking for any examples, ideas, comments before I start trying things out.

    Assuming that I understand your question correctly, it would seem to be the best way to do this would be to pass the Execution object to the DLL (either through a direct pass of the Execution object or passing the sequence context, from which you can get the Execution).  Then simply call Execution.NewThread, specifying the SequenceFile object (accessible from Engine.GetSequenceFileEx) and then passing the Thread object out as an output.  Your sequence file in which your DLL is called could then simply have a Wait step which is configured to wait on that Thread object.  What happens in this case is that the results are collected for that thread (which is being executed asynchronously) and returned as the results for the Wait step.
    Although you are probably not using LabVIEW, I have attached an example of this in LabVIEW that might be helpful just for seeing the flow.
    Thanks,
    Andy McRorie
    NI R&D
    Attachments:
    thread_test.seq ‏32 KB
    testthread.vi ‏19 KB

  • Time Machine backup created on Mac with a large hard disk. What happens when restore to MacBook Air with small SSD drive?

    What if a Time Machine backup was created on a Mac with a large hard disk, e.g. 500GB iMac - and I buy a new MacBook Air with a small SSD hard disk e.g 128GB. What happens when I need to use the larger Time Machine file to set up the new MacBook Air? What happens to all those files that can't fit on the smaller SSD drive?

    It is not the HD size, but rather the size of the data it contains. If you right-click your 500GB drive and select "Get Info" you can see how much is actually being used.
    Naturally if you are using more space than the new drive has, then you have to make some choices about what you want to keep and what you want to keep archived.
    I don't know what options are available but you may simply have to do a manual restore of files you want, in groups.

  • What happen if idoc extension will be changed ?

    HI,
    we are using a BPM (a big one) with a Multimapping zMATMAS03(Source) & RFC(Source) to MATMAS05(Target).
    The source(zMATMAS03) IDoc has a extension(German Erweiterung) with new Segment ZZxxx and new Fields ZZyyy.
    What happen if the allready importet and mapped zmatmas03 Idoc will be changed in the source system ?
    Example. We added 2 new Fields in the old zzxxx segment.
    Did i have to map everything new if i import the new idoc ? or did the new field are added to the old idoc and the mapping is working again ?
    Regards,
    Gordon

    Hi,
    1. you have to reimport the idoc from IR
    2. you should delete the old idoc definition in TCODE - IDX2
    3. you have to change your mappings so that they will use the new IDOC
    Regards,
    michal

  • I came home to NO bookmarks on my ipad2.  What happened with ios6 where all kinds of users have lost their bookmarks?

    No bookmarks on my ipad2 after new ios6 install.  What happened?  Fix it!

    Bookmark
    http://i1224.photobucket.com/albums/ee374/Diavonex/Album%201/4a4bacfd13c50890e48 b1a075cfa0e8f_zps9718c36a.jpg

  • What happens when license keys expire?

    We might pass our expiration date before we get new licenses purchased. What happens when AV and Anti-Spam keys expire?

    Hello Brian,
    if a feature key expires, the service for that feature will stop working, however mail processing (receiving, filtering, reporting, delivery, etc) will continue as usual.  In case you have placed the renewal order already, you might contact your Cisco IronPort Sales representative and ask for temporary keys until the renewal is finished, that is often posssible, and will keep you protected.
    Hope that helps,
    Andreas

  • Firmware update - what happens if I lose power?

    First update on new iMac with Mavericks - what happens if I lose power during the installation? Had problems with my Macbook after this situation.

    This is why backing up your data prior to any installation is a mandatory facet of using computers.

  • Cannot reply to forum post without being registered; but can't register without creating a new thread

    I wished to reply to a forum post with new information that will be of relevance to anyone searching for a solution to a particular problem. I did not have a support account with Mozilla. I found that the site would not allow a reply from an unregistered person. Fair enough, but it gives you no way to create an account then reply to the post. The only way you can create an account is by creating a new thread - which is what I am doing now! Crazy or what? It then took about 10 minutes thrashing about on the site to find out how to create an account. Frustrating or what? Thank goodness Firefox itself is built to much higher standards.

    Suggested fix for an admin to apply:
    Replace the text that appears at the bottom of a thread while signed out - "You must log in to your account to reply to posts. Please start a new question, if you do not have an account yet."
    ...with one that reads "You must log in to your account to reply to posts. Please [https://support.mozilla.org/get-involved sign up to contribute], or start a new question, if you do not have an account yet."
    This little seeming catch-22 gave me a chuckle, but I'm glad this thread was already here so that I didn't have to waste space. Someone needs to fix this soon though, lest it put more people off contributing.

  • What happens when you have a 40GB Apple TV and a 80gb itunes Library?

    Sorry, couldnt find the answer to this. Have a large library, and wanting to sync to new apple tv.
    What happens, do I only get a parcial library showing up in Apple TV?

    Even though tv is a remote network device, it shows up in iTunes just like a locally connected iPod or iPhone.
    From the iTunes library (of the computer hosting your media) the summary page displays a message that iTunes will sync to the tv in the order: movies, then tv shows, then music, then podcasts, then photos.
    It will copy as much as it can fit. OR you can go to each of the tabs (in iTunes after having selected the tv device) and pick which movies, music, photos, etc. that you'd like to copy.
    As an alternative, on the tv itself, there's a 'Source' menu. In addition to the content locally sync'd into the tv, it'll also display any iTunes library on your network, but the computer must be running iTunes and iTunes must have sharing enabled.
    If the tv is connected via a fairly fast network then live streaming from another computer is no problem. It will "work" with 802.11g wireless - but I noticed back when I used to run it this way that if I told iTunes to 'sync' to the tv it would take a very very long time to complete. So long, in fact, that I used to just do this over-night while I sleep. I think that it suspends syncing if I play a movie (at least if it isn't suspended, it's making such slow progress that I can't notice it). BUT... the tv does support both 802.11n wireless as well as 1000baseT (gigabit) wired networking. If you connect via either of these methods (esp. the gigabit wired), a full-sync will take mere minutes to do your whole hard-drive. It's amazingly fast. So streaming movies from another computer (instead of copying them locally into the tv) is no problem at all.

Maybe you are looking for