Search:

Type: Posts; User: spjackson; Keyword(s):

Page 1 of 10 1 2 3 4

Search: Search took 0.02 seconds.

  1. Replies
    4
    Views
    5

    Re: creating a pthread

    glibc's malloc is thread safe. I think that mallocs that you are likely to come across in this day and age will be thread safe. It is guaranteed to be in C11 (but not in C99).

    You will not...
  2. Replies
    4
    Views
    5

    Re: creating a pthread

    pthread_create succeeds, then immediately you return from main. returning from main terminates all running threads and stops your program. So your mt function never gets chance to print its message,...
  3. Replies
    4
    Views
    5

    Re: awk help, new to awk

    NR is an awk built-in variable that contains the current line number, starting at 1. So
    awk '{print NR, $0}' would output all the lines of the input file with each line being preceded by the line...
  4. Replies
    4
    Views
    5

    Re: awk help, new to awk

    How about something like this?


    # Replace the line following unique_xml_tag with the contents of /etc/motd
    awk 'BEGIN { target=-1 ; }
    /unique_xml_tag/ { target = NR+1 ; }
    { if (NR==target)
    ...
  5. Thread: mysqldump

    by spjackson
    Replies
    12
    Views
    13

    [ubuntu] Re: mysqldump

    The correct syntax is "-p[password_user_root]" without a space. (As already said, it's not a good idea to do this, but if you are going to do it anyway you need the correct syntax.) This is also the...
  6. Replies
    18
    Views
    19

    [SOLVED] Re: Unable to access jarfile

    That is surprising because the ClassLoader error you are getting is precisely what you would get when running some Java 8 code from Java 9 or above. The issue is explained here. Note in particular...
  7. Replies
    18
    Views
    19

    [SOLVED] Re: Unable to access jarfile

    I don't know anything about the specifics of running this particular jar, but I do know something about what is needed for java to execute a jar. If the above command is giving you the above message...
  8. Re: python 3 tqdm module deleting a directory

    The reason you are getting the error is this. Your for loop says to call rmtree 100 times with the same path. Once the first iteration of the loop completes successfully, the directory no longer...
  9. Replies
    3
    Views
    4

    [ubuntu] Re: I screwed up QT5

    The link you provide for the PPA indicates that the package installs everything in /opt. It says "Source /opt/qt512/bin/qt512-env.sh to set the correct environment."

    My take on that is that the...
  10. [SOLVED] Re: how to fix ' ModuleNotFoundError: No module named 'tkinter' ' error ?

    sudo apt install python3-tk
  11. Replies
    2
    Views
    3

    [ubuntu] Re: gVim menus disappeared

    As I understand it, there are 2 possible causes: menus are disabled in gVim settings or the window manager is "showing" the menu bar in some invisible place. For the first case, if you do:

    :set...
  12. [SOLVED] Re: Two users at the same time - one in background

    Instead of logging out, if you lock the screen, then a second user can login from the locked screen.
  13. Replies
    2
    Views
    3

    Re: rsync intermittent failures

    @TheFu Thanks for your reply. Yes it is ssh. Your suggestions are worth looking into - I will do this.
  14. Replies
    2
    Views
    3

    rsync intermittent failures

    As per this thread I am backing up a website using rsynch thus:

    rsync -avz --copy-links user@some-ftp.site.com: .
    Intermittently it fails with:


    receiving file list ... Write failed: Broken...
  15. Replies
    3
    Views
    4

    Re: Using bzip2 in a C program on Ubuntu

    gcc main.c -lbz2
    Some time ago, gcc was changed to require libraries to occur after the code that used them. Once upon a time it didn't matter.
  16. [xubuntu] Re: /snap/bin in PATH but directory does not exist

    You get /snap/bin in your path because of /etc/profile.d/apps-bin-path.sh which is provided by the snapd package. I believe that recent versions of all Ubuntu flavours, including Server (don't...
  17. Replies
    7
    Views
    8

    [ubuntu] Re: Problem with makefile error cs0009

    You need a programmer with expertise in mono and mcs and possibly Steam. While it may be possible that someone here can help you, I'm not sure that "New to Ubuntu" is the best forum in which to find...
  18. Thread: Qt5-sdk

    by spjackson
    Replies
    1
    Views
    2

    Re: Qt5-sdk

    I'm not sure which version of Ubuntu you are on. For 18.04 the following should be sufficient. The same list may also work with 19.


    sudo apt install build-essential qttools5-dev-tools qt5-qmake...
  19. Replies
    11
    Views
    12

    Re: python variable type

    Yes. This is an aspect of dynamic typing. If you want to declare a variable of a particular type and to ensure that only values of that type can be assigned to it, then you need a statically typed...
  20. [SOLVED] Re: pydf - adding strange characters to redirected output

    Those characters are part of escape sequences to change the colour of text in the terminal. These escape sequences are not interpreted by the printer. Use the following to disable colour switching.
    ...
  21. Replies
    2
    Views
    3

    [SOLVED] Re: Damaged .WAV file

    Thank you so much. Why didn't I notice that? That's worked.
  22. Replies
    2
    Views
    3

    [SOLVED] Damaged .WAV file

    I have a portable Digital Voice Recorder which records audio and saves in .WAV format. This normally works fine but on the odd occasion the .WAV file is damaged in some way. At present I have such a...
  23. [SOLVED] Re: How with grep command exclude search in dubdirectory ?

    grep -Hrn 'backend' --include="*.vue" /mnt/_work_sdb8/wwwroot/lar/hostels2/resources/js/components/BS4 | grep -v /admin/
  24. Re: preserve permissions while zip folders

    Welcome to the forums.

    The zip and unzip commands in the zip package are from Info-Zip and these normally preserve permissions where possible. An alternative would be to use a compressed tar, if...
  25. Replies
    6
    Views
    7

    Re: Make mv not move directories

    This is a very interesting question.


    * matches 'Corbeil'
    [A-Z] matches 'l' (for many collations)
    ? matches 'e'


    *[A-Z]? would not match bbbbab because 'a' is outside the range A-Z...
Results 1 to 25 of 250
Page 1 of 10 1 2 3 4