Results 1 to 3 of 3

Thread: Avoid Warning "Invalid parameter passed to C runtime function"

  1. #1
    Join Date
    Apr 2019
    Posts
    3
    Qt products
    Qt5

    Question Avoid Warning "Invalid parameter passed to C runtime function"

    I have a complex Qt project and by debugging I get plenty of
    "Invalid parameter passed to C runtime function." outputs in console.

    How can I disable this warning? Please help!

  2. #2
    Join Date
    Jan 2008
    Location
    Alameda, CA, USA
    Posts
    4,884
    Thanks
    274
    Thanked 794 Times in 784 Posts
    Qt products
    Qt5
    Platforms
    Windows Android

    Default Re: Avoid Warning "Invalid parameter passed to C runtime function"

    How can I disable this warning?
    I think I would disable it by finding out what is wrong with the code and fixing it. Warnings are there for a reason, and something like this usually means you are really doing something wrong.
    <=== The Great Pumpkin says ===>
    Please use CODE tags when posting source code so it is more readable. Click "Go Advanced" and then the "#" icon to insert the tags. Paste your code between them.

  3. #3
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,708
    Thanks
    13
    Thanked 1,603 Times in 1,530 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Avoid Warning "Invalid parameter passed to C runtime function"

    Quote Originally Posted by QMAsker View Post
    I have a complex Qt project and by debugging I get plenty of
    "Invalid parameter passed to C runtime function." outputs in console.

    How can I disable this warning? Please help!

    It is likely you can't, the warning is not coming from your code at compile/link time, it is coming from a Microsoft C runtime at run time. BTW, I am guessing you are on Windows.
    There are known Microsoft bugs that cause this in Qt usage, e.g.
    https://bugreports.qt.io/browse/QTBUG-70917, but we have no way to know if these apply to you.
    Absent any useful detail in your post it is not possible to offer further assistance.
    "We can't solve problems by using the same kind of thinking we used when we created them." -- Einstein
    If you are posting code then please use [code] [/code] tags around it - makes addressing the problem easier.

  4. The following user says thank you to ChrisW67 for this useful post:

    d_stranz (24th March 2021)

Similar Threads

  1. Invalid parameter passed to C runtime function
    By Satansoft in forum Newbie
    Replies: 7
    Last Post: 29th November 2014, 15:33
  2. Replies: 1
    Last Post: 9th January 2014, 15:31
  3. Replies: 4
    Last Post: 4th January 2012, 22:43
  4. Replies: 0
    Last Post: 24th October 2010, 19:09
  5. Replies: 1
    Last Post: 25th September 2010, 08:20

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.